# Architecture Decision Records (ADR)

This directory contains Architecture Decision Records for the Crafted SaaS template.

## What is an ADR?

An ADR documents an important architectural decision, including:
- The context and problem statement
- The decision made
- The rationale behind it
- Consequences (positive, negative, neutral)
- Alternatives considered

## Why ADRs?

1. **Knowledge Transfer**: New team members understand why decisions were made
2. **Historical Context**: Remember why we chose X over Y
3. **Review & Challenge**: Decisions can be reviewed and changed with context
4. **Alignment**: Team agrees on architectural direction

## ADR Index

| Number | Title | Status | Date |
|--------|-------|--------|------|
| [001](./001-hexagonal-architecture.md) | Hexagonal Architecture | Accepted | 2024-10-12 |
| [002](./002-result-pattern-over-exceptions.md) | Result Pattern Over Exceptions | Accepted | 2024-10-12 |
| [003](./003-zero-dependencies-domain-layer.md) | Zero Dependencies in Domain Layer | Accepted | 2024-10-12 |

## Status Types

- **Proposed**: Under discussion
- **Accepted**: Approved and implemented
- **Deprecated**: No longer recommended
- **Superseded**: Replaced by another ADR

## Creating a New ADR

1. Copy template:
   ```bash
   cp docs/adr/template.md docs/adr/XXX-title.md
   ```

2. Fill in sections:
   - Context
   - Decision
   - Rationale
   - Consequences
   - Alternatives

3. Submit for review

4. Update this README with new entry

## References

- [ADR GitHub](https://adr.github.io/)
- [Architecture Decision Records](https://cognitect.com/blog/2011/11/15/documenting-architecture-decisions)
