Sub-agents, multi-agent orchestration, the Claude Code SDK, CI/CD automation, and scheduled tasks
Use → to reveal tips • ← to go back • ↓ next slide • ↑ previous slide
Specialised AI agents that Claude delegates specific tasks to, each with its own context and tools.
# .claude/agents/security-reviewer.md --- description: "Reviews code changes for security vulnerabilities" allowed-tools: Read, Grep, Glob model: opus --- You are a security reviewer. Analyse the given code for: - Injection vulnerabilities (SQL, NoSQL, command, XSS) - Authentication/authorization flaws - Sensitive data exposure - Insecure dependencies
api-designer (OpenAPI expert), test-writer (generates comprehensive test suites), perf-analyser (profiles and optimises), doc-writer (API docs from code).
Multiple agents working together on complex tasks.
code-writer → test-writer → security-reviewer → doc-writer. Each agent receives the previous agent's output.
test-writer creates tests, doc-writer generates docs — both from the same code change.
"Implement the user notifications feature: 1. Read the spec in docs/notifications-spec.md 2. Implement the backend endpoints 3. Write comprehensive tests 4. Review for security issues 5. Update the OpenAPI spec 6. Create the PR with a full description"Claude orchestrates multiple sub-agents for each step.
Run Claude Code from your own scripts, CI pipelines, and applications.
@anthropic-ai/claude-code npm package lets you invoke Claude Code programmatically from Node.js. Full agent capabilities in your scripts.
import { claude } from "@anthropic-ai/claude-code";
const result = await claude({
prompt: "Run tests and fix any failures",
workingDirectory: "./my-project",
allowedTools: ["Bash", "Read", "Write", "Edit"],
model: "sonnet"
});
# .github/workflows/claude-review.yml
- name: Claude Code Review
uses: anthropics/claude-code-action@v1
with:
prompt: "Review this PR for bugs, security, and style"
allowed_tools: "Read,Grep,Glob"
Put Claude to work in your deployment pipeline.
claude-code-action in GitHub Actions. Every PR gets automatic code review comments — security checks, style issues, potential bugs.
claude -p "Verify this branch is ready to merge: 1. All tests pass 2. No TODO/FIXME markers 3. OpenAPI spec matches implementation 4. No console.log statements in production code" --allowedTools Bash,Read,Grep
claude -p "Generate a changelog from the commits since the last tag, grouped by feat/fix/chore" — automate your release notes.
claude -p "Run npm audit, analyse the vulnerabilities, and create a PR fixing any that can be auto-patched"
--allowedTools to restrict what Claude can do. Never use --dangerously-skip-permissions on shared runners without careful scoping.
Set it and forget it — Claude working on a schedule.
# Every morning at 9am — pull latest, run tests, report failures claude -p "Pull main, run full test suite, and if anything fails, create a GitHub issue with the details" # Weekly on Monday — dependency audit claude -p "Run npm audit and create a PR fixing critical vulnerabilities" # Nightly — code quality report claude -p "Analyse code quality metrics and post a summary to #engineering Slack"
"Monitor the CI pipeline. If a test fails on main, analyse the failure, create a fix, and open a PR." — Claude as your on-call bot.
Level up how you communicate with Claude for better, faster results.
"Using only the existing OrderService methods, no new dependencies, and keeping backward compatibility — add bulk order creation to POST /orders"
"Add input validation. Here's the pattern from our user endpoint: [paste 5-line example]. Apply the same pattern to the /orders endpoint."
"Don't use try/catch for flow control — we use Result types. Don't import from /handlers/ in /services/. Don't use any from TypeScript."
"Walk through the request lifecycle for POST /orders step by step. At each stage, check if the data could be null or malformed."
"Act as a senior backend engineer reviewing a junior's PR. Be thorough but constructive. Focus on security, performance, and maintainability."
How to get the whole team productive with Claude Code.
/init on each project. Learn: interactive mode, one-shot, /clear, /compact, /cost. The 2 experienced members pair with newcomers.
Official docs, free courses, video tutorials, and community guides to deepen your Claude Code skills.
Level 1 today. Level 4 by the end of the quarter.
The best prompt is the one you don't have to type again.
Resources:
code.claude.com/docs ·
github.com/anthropics/claude-code ·
/help inside any session