In any technical team, an inevitable tension arises sooner or later:
Which tasks should be executed manually and which can be safely delegated to an AI?
We —my team— are answering it. In this article, I tell you the whole process.
We start with a clear example: the automation of AVO events.
For this, we have used a very special AI tool: Claude Code.
But let me tell you the whole story.
What is Claude Code and why automate with it?

Important. Claude Code is just one example of an agent that lives in the terminal. There are other options, you just have to look. The important thing is that nothing you will learn here is exclusive to Claude Code.
Claude Code is not another copilot inside the editor.
It is a tool designed to automate technical tasks through structured prompts, executed from the terminal.
It functions as a command-line tool capable of:
- Reading a complete project.
- Maintaining context between sessions.
- Integrating into real workflows (CI/CD, scripts, terminal).
- Sharing versioned commands with the team.
- Among many other things.
Advantages of using Claude Code CLI vs Copilot
In the three weeks I've been working with Claude Code, I have to say I am impressed.
Claude is more or less accepted as the best model for coding. Now, being able to use it from the terminal takes it to another level.
These are the aspects that stand out for me, but I recommend you take a look at its documentation.
Takes decisions and executes: from copilot to operative agent
Many AI tools for development stay at the suggestion layer.
Claude Code goes a step further: it takes direct action.
It doesn't limit itself to completing code. It edits files, executes commands, creates branches, makes commits, generates PRs.
This turns it into an operative tool, not just an assistive one.
If you need to go beyond your local repository/project, Claude can integrate with your real work system through MCP (Multi-Context Prompting). To delve deeper into this, review my article on what MCP is and how it changes your flow.
This allows it to access:
- Documentation in Google Drive.
- Tickets in Jira.
- Distributed repositories or monorepos.
- Internal development tools.
Lives in the terminal: our common language
Claude Code does not depend on the development environment.
It works the same whether you work with code editors like Visual Studio Code, with IDEs like WebStorm, or skip GUIs with VIM/NeoVIM (in fact, it has VIM mode ❤️).
One of the most widespread errors in the design of AI tools is assuming that all Web professionals share the same editor.
That is not true. But there is a real point of convergence: the terminal.
The terminal is the only truly common language among developers.
That's why Claude Code runs there, without a graphical environment, without plugins (although it has them, if that's what you want), without lock-in. Just text, context, and commands.
$claude "analyze GraphQL query structure"
$claude "generate integration tests for Auth module"
$claude "refactor Vue components in src/components"
This approach makes it a portable, interoperable, and useful tool for any technical profile, regardless of their stack or editor preferences.
Unix philosophy applied: Claude Code is part of the system
Claude Code is not designed to accompany you while you write code line by line.
It is designed to compose with your system, like any tool based on Unix principles: standard input and output, piping, small commands that do one thing and do it well.
It is not a plugin. It is a piece of the operating system.
# Detect changes in translation files and create a PR with newly translated strings
git diff main...HEAD -- src/i18n | claude -p "Detect new English strings and generate a PR with their Spanish translations for review"
# Monitor the development console log and notify if a new error pattern is detected
tail -f logs/dev-console.log | claude -p "Notify me if a new error pattern appears in this log stream"
# Analyze Vue components and identify missing unit tests
find src/components -name '*.vue' | claude -p "For each file, check if a corresponding unit test exists and suggest missing test cases"
Claude Code does not try to guess what you want to say. It executes exactly what you ask, with precision, without assuming your context or depending on your editor.
This —for me— makes it a more real tool, not a prosthesis.
What tasks to delegate to Claude Code (Use Cases)
Claude Code can take care of tasks that combine analysis, transformation, and execution: it not only generates code, but executes it, leaves traceability, and integrates it into your workflow.
Building features from descriptions
- Claude generates the structure, updates components, creates tests, and proposes a complete PR.
Error debugging
- Claude analyzes the code, locates the failure, applies the fix, and validates with tests or usage examples.
Navigation through complex projects
- Claude reads the complete structure, identifies dependencies, documents flows, and orients you with precision (for me this is revolutionary). If you want to learn how to navigate projects like a pro, read my Claude Code professional guide.
Automation of repetitive tasks
- Claude edits, formats, creates commits, and leaves history clean, executing everything from your terminal (what we are doing here).
Advanced operations via MCP
- If your flow implies external documentation, ticket management, or design resources, MCP (Model Context Protocol) expands capabilities:
- Reads Google Docs with UI specifications and applies those decisions in code.
- Updates Jira tickets with status and links to PR.
- Interacts with internal tools: Storybook, custom migrators, CI/CD workflows.
Case Study: Automating AVO Events
We started with the implementation of tracking events —like those of AVO.
It seems, at first glance, a routine task. But in reality, it combines multiple steps with technical dependencies, cross-validation, and repeatability.
When it comes to several events and/or the destination system is unknown, the human time invested grows exponentially.
The solution? Design a reusable command, shared among the whole team, and backed by an AI capable of understanding the complete project context.
Reusable commands: .claude/commands/
In my opinion, the true power of Claude Code is in the ability to define custom commands versioned alongside the project.
For the described case (AVO), we created a command called implement-avo-event, which encapsulates all the necessary steps to add an AVO event.
Commands are, in reality, prompts where you must provide all the necessary context so the agent does its job optimally and avoids hallucinations.
To add a command, simply create a Markdown file in the .claude directory of your project (you can version it and share the command with the rest of the team).
File PROJECT_DIR/.claude/commands/implement-avo-event.md
1. Ask me for clarification regarding ANY step.
2. If I don't provide #$ARGUMENTS, ask me, independently, for EVENT_NAME, BRANCH_NAME, AVO_BRANCH_NAME and comma-separated FILES_TO_APPLY the event.
3. If I do, parse the space-separated arguments from #$ARGUMENTS.
4. Extract: EVENT_NAME, BRANCH_NAME, AVO_BRANCH_NAME and comma-separated FILES_TO_APPLY to apply the event.
5. Before starting, make sure the event and the file/s exists.
6. Create and checkout a new GIT branch named [BRANCH_NAME].
7. Checkout AVO branch using: `avo:checkout [AVO_BRANCH_NAME]`.
8. Read `@avo-types/events.ts` for [EVENT_NAME] definition.
9. Add the event to `src/tracking/events.ts`, following the file pattern.
10. Check the `EventTracker` class located in `src/tracking/tracker.ts` for context.
11. Implement the new event in specified [FILES_TO_APPLY].
12. Generate essential unit tests (make sure you are not breaking existing ones).
13. Create a basic GitHub PR detailing, in a to-do list fashion, what you have done. Follow conventional commits.
As you can verify, we have access to $ARGUMENTS to customize the command and make it even more versatile. It is the way Claude understands what I refer to with EVENT_NAME, BRANCH_NAME, AVO_BRANCH_NAME, and FILES_TO_APPLY.
Using the command
$claude /implement-avo-event PurchaseCompleted feature/purchase avo/purchase src/checkout.ts,src/analytics.ts

What does it do?
If you have created a good prompt/command, reading it will be enough to understand its operation:
- Reads existing definitions.
- Asks appropriate questions to obtain all context.
- Examines the codebase.
- Incorporates the new event from AVO.
- Implements the correct pattern.
- Adds tests.
- Generates a PR with description and detailed checklist.
You remain in control
Claude gets to work when it has all the necessary context. When it does, by default, it will propose what it wants to do and you will have to validate it.
Once this phase is passed you can indicate it to do it on its own, further reducing the time needed to perform the action.

It is much more than a command
Something that may go unnoticed but is vital to understand is that this is much more than a command:
You are not activating an inert process. You are communicating with an AI entity that can answer you.
This completely changes the perspective, since each session can be radically different from the previous one, allowing you to focus your efforts on solving a problem instead of writing boilerplate.
Results: Time Savings and ROI

After implementing the command the results are promising. Most events are included (with validations and incorporation) in a matter of minutes. If it is a more abstract context it is possible that Claude requires more "hand-holding", but even so you are automating most of the process.
Let me summarize it for you:
Before (Manual)
- Data team defines AVO event.
- Developer receives definition.
- Implements event "by hand".
- Writes tests.
- Validates entire flow.
- Creates change incorporation (PR).
Now (Automated)
- Data team defines AVO event.
- Developer receives definition.
- Developer executes a command that handles steps 3, 4, 5, and 6.
Difference (ROI)
- Before: 1–3 hours per event.
- Now: less than 5 minutes.
- Gain: time, context, consistency.
Also, the difference is not just technical. It's context. Many details of the AVO system are not formally documented. Validation cost is high and difficult to estimate without automation.
How much does Claude Code really cost? (Tokens and Pricing)
One of the most frequent questions about AI tools is operational cost. It is understandable: enterprise solutions usually have opaque prices, and individual development tools do not always scale well to teams.
Claude Code operates with a transparent pricing model based on processed tokens. Below, I show you the real cost breakdown for our specific use case, without inflated estimates or ideal scenarios.
Per command executed:
| Concept | Tokens | Cost |
|---|---|---|
| Input (context + files) | ~4,000 | $0.012 |
| Output (code + tests + PR) | ~6,000 | $0.090 |
| Total per AVO event | 10,000 | ~$0.10 |
Profitability comparison:
| Method | Time | Estimated cost |
|---|---|---|
| Manual | 2-3 hours | ~150 € (developer time) |
| Claude Code | 3-5 minutes | $0.10 + $15 (approx. review) |
| Real savings | ~95% | ~92% |
In practice:
- 10 events per sprint = $1.00 in tokens.
- Time savings = 20-30 hours.
The bottleneck is not money. It is time to value and the learning curve.
Real Benefits and Limitations
What works especially well
- Quality of generated code.
- Structure recognition.
- Immediate adoption.
- Automated documentation.
- Continuous integration.
Current limitations
- Limited context in really large projects.
- Cost per tokens, if abused or necessary context is not provided.
- Non-deterministic results (require review).
Conclusion
Claude Code is a tool that can integrate with your real workflow and transform processes that were previously inefficient, tedious, or prone to human error.

Instead of limiting itself to generating code, Claude operates. Takes decisions, edits, executes, validates. And it does so from the universal language that every technical team shares: the terminal.
But don't get confused: this doesn't mean you can delegate everything.
- If a task is repeatable, contextual, and based on patterns: it can be delegated.
- If a task requires judgment, validation, or critical decision: it must be reviewed.
- If a task requires creativity or deep criteria: it cannot be delegated, yet. But you can automate the remaining 80%.
And most importantly: you maintain control. It is not about disconnecting from the process, but about elevating the point where you add value.
Main takeaways
- Claude Code is an operative agent, not a passive copilot. Takes real action.
- Lives in the terminal, not in your editor. Portability and total control.
- Integrates with your real work system (CI/CD, Jira, GDocs) via MCP.
- You can define versioned commands that encapsulate advanced prompts.
- Automates real tasks: event integration, tests, refactor, PRs.
- Saves hours per task. Literally.
- Costs cents. The bottleneck no longer has to be money, but will.