How to run an autonomous agent against your ad accounts
What changes when nobody is at the keyboard, and how to bound what an autonomous agent can do.
Both readings are on this page.
For you
What the answer looks like, and what to type to get it.
The way this normally goesLink to this section
- Give a cron job an API key with full account access, and read the logs afterwards.
The way it goes with an assistantLink to this section
- Tick only the accounts the agent may reach. The allowlist is enforced server side on every call.
- Keep it on a plan without writes if it should only ever read.
- Let the monthly allowance be the backstop on a loop that goes wrong.
Prompts to start fromLink to this section
Things worth running on a scheduleLink to this section
Every morning, list any campaign whose CPA rose more than 30 percent against its 7 day average.
Every Monday, produce the cross-platform table for last week.
Alert me when a Google Ads campaign stops spending entirely.
Watch Search Console for pages that lost more than 20 percent of their clicks.Tools this usesLink to this section
| Tool | Why |
|---|---|
list_accounts | First call of every run. It is the cheapest way to notice a revoked connection. |
search_tools | Rather than hard-coding a tool name that may be renamed. |
describe_tool | Read the schema at run time instead of assuming it. |
run_tool | Execute. The same checks run as on a direct call. |
What it will not doLink to this section
- An agent cannot connect a platform or tick an account. Both are consent decisions that need the account owner.
- A refused call costs no quota, but a retry loop still spends the calls that succeed before it.
- Writes preview by default. An unattended agent that never sends confirm changes nothing, which is the safe failure.
For your agent
The tool sequence, the parameters that matter, and what will be refused.
Both readings as Markdown: /guides/unattended-agents.md
This job reads several sources, across 4 tool calls. It changes nothing, so it works on every plan.
SequenceLink to this section
| Step | Tool | Purpose |
|---|---|---|
| 1 | list_accounts | First call of every run. It is the cheapest way to notice a revoked connection. |
| 2 | search_tools | Rather than hard-coding a tool name that may be renamed. |
| 3 | describe_tool | Read the schema at run time instead of assuming it. |
| 4 | run_tool | Execute. The same checks run as on a direct call. |
Constraints that will refuse youLink to this section
- Only the ad accounts the account owner ticked are reachable. Call
list_accountsfirst rather than guessing an identifier. - An agent cannot connect a platform or tick an account. Both are consent decisions that need the account owner.
- A refused call costs no quota, but a retry loop still spends the calls that succeed before it.
- Writes preview by default. An unattended agent that never sends confirm changes nothing, which is the safe failure.
What the person is likely to askLink to this section
Every morning, list any campaign whose CPA rose more than 30 percent against its 7 day average.
Every Monday, produce the cross-platform table for last week.
Alert me when a Google Ads campaign stops spending entirely.
Watch Search Console for pages that lost more than 20 percent of their clicks.