Creating Agents
Build your first background agent step by step
Ready to automate something? This guide walks you through creating your first background agent.
Before You Start
Make sure you have:
- A Billix account
- At least one integration connected (like Gmail or Slack)
- An idea of what you want to automate
Creating Your First Agent
Go to Agents
Click "Agents" in the left sidebar. You'll see any existing agents and a "Create New Agent" button.
Click Create New
Click the "Create New Agent" button to open the agent builder.
Name Your Agent
Give it a clear, descriptive name:
- Good: "Daily Email Summary"
- Good: "GitHub PR Notifier"
- Bad: "Agent 1"
- Bad: "Test"
A good name helps you find and manage agents later.
Write Instructions
This is the most important part. Write clear, specific instructions for what the agent should do:
1. Check my Gmail inbox for unread emails from the last 24 hours
2. Filter for emails that appear to be important or urgent
3. Create a summary of each important email including:
- Sender name
- Subject line
- Key points (2-3 sentences)
4. Format the summary as a bulleted list
5. Send the summary to me via emailTip: Be specific! Instead of "check my emails," say "check my Gmail inbox for unread emails from the last 24 hours."
Choose an AI Model
Select the model that powers your agent:
| Model | Best For |
|---|---|
| GPT-4o | General tasks, good balance |
| Claude 4 Sonnet | Writing, analysis, nuanced work |
| GPT-4o Mini | Simple tasks, cost-effective |
Start with GPT-4o if unsure.
Select Tools & Integrations
Choose which connected services the agent can access:
- Toggle on the integrations it needs
- Only enable what's necessary (principle of least privilege)
- The agent can only use enabled integrations
Configure Trigger
Set when the agent runs:
Schedule: Runs at specific times
- Daily at 8:00 AM
- Every Monday at 9:00 AM
- Every hour
Webhook: Runs when called by external service
- You'll get a unique URL to trigger the agent
Manual: Runs only when you click "Run Now"
Set Notifications
Choose how to be notified when the agent completes:
- Email: Receive results in your inbox
- In-app: See notifications in Billix
- None: Check logs manually
Test Your Agent
Before activating, test the agent:
- Click "Test Run"
- Watch the execution in real-time
- Review the output
- Make adjustments if needed
Activate
Once testing succeeds, click "Activate" to turn on the agent. It will now run according to its trigger.
Writing Good Instructions
Structure Your Instructions
Use numbered steps for clarity:
1. [First action]
2. [Second action]
3. [Third action]
4. [Output action]Be Specific
Check my emails and summarize them.Problems:
- Which email account?
- All emails or just unread?
- What time range?
- How detailed should the summary be?
1. Check my Gmail inbox for unread emails received in the last 24 hours
2. For each email, extract:
- Sender name and email
- Subject line
- 2-3 sentence summary of the content
- Whether it seems urgent (yes/no)
3. Sort by urgency (urgent first)
4. Format as a numbered list
5. Send the formatted summary to me via email with subject "Daily Email Digest"Handle Edge Cases
Tell the agent what to do in special situations:
If there are no unread emails, send a brief message saying
"No new emails to report."
If there are more than 20 emails, summarize only the 10 most
recent and note that there are more.Include Format Examples
Show the agent what you want:
Format each email summary like this:
**From:** John Smith (john@example.com)
**Subject:** Q4 Budget Review
**Summary:** Requesting review of the Q4 budget proposal before
the board meeting on Friday.
**Urgent:** YesCommon Agent Patterns
Daily Digest Pattern
Name: Daily Email Digest
Trigger: Daily at 7:00 AM
Instructions:
1. Check Gmail for unread emails from the last 24 hours
2. Categorize by priority: High, Medium, Low
3. Summarize high-priority emails in detail
4. List medium and low priority with subject lines only
5. Send digest email with subject "Your Daily Digest - [Date]"Monitor and Alert Pattern
Name: Important Email Alert
Trigger: Every hour
Instructions:
1. Check Gmail for unread emails from the last hour
2. Look for emails containing "urgent," "ASAP," or "deadline"
3. If found, immediately send me a Slack message in #alerts
with the sender and subject
4. If none found, do nothing (no notification needed)Weekly Report Pattern
Name: Weekly Project Report
Trigger: Every Friday at 4:00 PM
Instructions:
1. Get all completed tasks from Notion's Project Board
from this week
2. Group by project and team member
3. Calculate completion rates
4. Create a summary report with:
- Total tasks completed
- Breakdown by project
- Top contributors
- Any blocked items
5. Post to #weekly-reports Slack channelAgent Builder Interface
The agent builder has these sections:
| Section | Purpose |
|---|---|
| Basic Info | Name, description |
| Instructions | Main prompt/instructions |
| Model | AI model selection |
| Tools | Enabled integrations |
| Trigger | Schedule, webhook, or manual |
| Notifications | Email, in-app, or none |
| Advanced | Timeout, retries, variables |
Testing Tips
Start Small
Begin with a simple version:
- Test with one action first
- Gradually add complexity
- Test each change
Use Test Mode
Test mode lets you:
- Run without side effects (when possible)
- See exactly what the agent does
- Review before enabling real actions
Check Logs
After each run:
- Go to the agent's detail page
- Click on the run in history
- Review the full execution log
- Look for errors or unexpected behavior
Troubleshooting
Next Steps
- Learn about trigger options
- Explore agent templates
- Read best practices
Was this page helpful? Let us know!
Report an issue