Aulafy

First Steps

Learn how to start Claude Code, understand its interface, and complete your first AI-assisted programming tasks.

Starting a Session

Open your terminal, navigate to your project directory, and run:

TerminalCode
claude

You'll see an interactive prompt like this:

TerminalCode
╔══════════════════════════════════╗
║  Claude Code  ·  claude-sonnet  ║
╚══════════════════════════════════╝
> _

Claude Code is ready to receive instructions in natural language. You can write to it as if it were a coworker.

Your First Task

Try something simple to get started. Type:

TerminalCode
> ¿Qué archivos hay en este directorio?

Claude Code will run ls or find and show you the result. You'll notice that before running any tool, it asks for confirmation or shows you what it's about to do.

Understanding the Workflow

Claude Code operates in cycles of:

  • Think — analyzes your request and plans the steps.
  • Act — uses tools (read files, run commands, edit code).
  • Show — presents the results and changes made.
  • Wait — returns to waiting for your next instruction.

Operating Modes

Normal mode (default)

Claude Code asks for confirmation before editing files or running important commands. Ideal for getting started and maintaining control.

Auto mode

Claude completes tasks autonomously without asking for confirmation at each step. Useful when you trust the task and want speed:

TerminalCode
claude --dangerously-skip-permissions

Plan mode

Type /plan before your request so Claude shows you the plan before executing anything. Ideal for complex tasks:

TerminalCode
> /plan refactoriza el módulo de autenticación para usar JWT

Examples of First Tasks

Understanding an Existing Project

TerminalCode
> Explícame la estructura de este proyecto y qué hace cada carpeta
TerminalCode
> ¿Qué hace la función processPayment en src/payments.ts?

Creating a New File

TerminalCode
> Crea un componente React llamado Button con variantes primary y secondary en TypeScript

Fixing an Error

TerminalCode
> Tengo este error en la consola: [pegar el error] — ayúdame a resolverlo

Running Tests

TerminalCode
> Ejecuta los tests y si hay fallos, corrígelos

Exiting Claude Code

You can exit with Ctrl + C, Ctrl + D, or by typing:

TerminalCode
> /exit

Starting with a Direct Prompt

If you know exactly what you want, you can pass it directly to the command without entering interactive mode:

TerminalCode
claude "explica el archivo package.json"
claude "añade tipos TypeScript al archivo utils.js"

"Print" mode (direct output)

To use Claude Code in scripts or pipelines:

TerminalCode
claude -p "resume los cambios en este diff" < cambios.diff

The -p flag makes Claude respond once and exit, ideal for automation.