# Backend Architect

> Expert backend architect specializing in scalable API design, microservices architecture, and distributed systems. Masters REST/GraphQL/gRPC APIs, event-driven architectures, service mesh patterns, and modern backend frameworks.

- Skill: `mileycy516-stack/backend-architect` (Agent Skill, multi-file: 4 files)
- Install (CLI): `npx skillmds@latest add mileycy516-stack/backend-architect`
- Raw SKILL.md: https://api.skillmd.com/api/skills/mileycy516-stack/backend-architect/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: mileycy516-stack (https://skillmd.com/u/mileycy516-stack)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/mileycy516-stack/backend-architect

---


# Backend Architect

Expert backend system architect specializing in scalable, resilient, and maintainable backend systems and APIs.

## When to Use This Skill
- Designing Microservices or Modular Monoliths
- Defining API Contracts (REST, GraphQL, gRPC)
- Implementing Event-Driven Architectures (Kafka, RabbitMQ)
- Designing Authentication/Authorization flows (OAuth2, JWT)
- Ensuring Resilience (Circuit Breakers, Rate Limiting)
- Planning Caching Strategies (Redis, CDN)

## Workflow
1.  **Boundaries**: Define Domains (User, Order, Payment). Avoid tight coupling.
2.  **Contracts**: Define the API-First (OpenAPI/Swagger or GraphQL Schema).
3.  **Communication**: Choose Async (Events) vs Sync (HTTP/gRPC).
4.  **Resilience**: Add Circuit Breakers and Retries.
5.  **Observability**: Plan Logging, Metrics, and Tracing from day one.

## Instructions

### 1. API Design
*   **REST**: Use standard verbs (GET, POST, PUT, DELETE). Use Plural nouns (`/users`). Return standard HTTP codes (200, 201, 400, 401, 403, 404, 500).
*   **GraphQL**: Good for flexible client data fetching. Watch out for N+1 queries (use DataLoader).
*   **Versioning**: Prefer Header versioning (`Accept: application/vnd.myapi.v1+json`) over URL versioning (`/v1/users`) if possible, but URL is often pragmatic.

### 2. Microservices & Communication
*   **Strangler Pattern**: Move legacy to microservices piece by piece.
*   **Saga Pattern**: Manage distributed transactions across services (Choreography vs Orchestration).
*   **BFF (Backend for Frontend)**: Create specific API layers for Mobile vs Web if needs diverge significantly.

### 3. Resilience Patterns
*   **Circuit Breaker**: Stop calling a failing service to give it time to recover.
*   **Bulkhead**: Isolate thread pools so one slow service doesn't crash the whole app.
*   **Idempotency**: Ensure retrying a payment request doesn't charge the user twice (use `Idempotency-Key` header).

## Resources
- [API Design Guide](references/api-design-guide.md)
- [Microservices Patterns](references/microservices-patterns.md)
- [Resilience & Security](references/resilience-security.md)

