# Laravel Architecture

> High-level architecture decisions, patterns, and project structure. Use when deciding which pattern to use, organizing code, or making structural decisions.

- **Type:** Skill
- **Install:** `agentstack add skill-leeovery-agentic-skills-laravel-architecture`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [leeovery](https://agentstack.voostack.com/s/leeovery)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [leeovery](https://github.com/leeovery)
- **Source:** https://github.com/leeovery/agentic-skills/tree/main/laravel/skills/laravel-architecture

## Install

```sh
agentstack add skill-leeovery-agentic-skills-laravel-architecture
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Laravel Architecture

High-level architectural guidance for Laravel applications.

## Core Concepts

**[philosophy.md](references/philosophy.md)** - Foundational principles:
- Declarative code above all else
- Strict separation of concerns
- Type safety first
- All core architectural principles

**[patterns.md](references/patterns.md)** - Pattern overview:
- Actions for domain logic
- DTOs for data transfer
- State machines for complex state
- Services for external integration
- Workflows for multi-step processes
- Value objects for domain values

**[decisions.md](references/decisions.md)** - Pattern selection:
- When to use each pattern
- Decision flowcharts
- Architectural trade-offs
- Common scenarios

**[structure.md](references/structure.md)** - Directory structure:
- Complete project organization
- File placement rules
- Namespace conventions
- Web vs API distinction

**[examples.md](references/examples.md)** - Reference implementations:
- Complete working examples
- End-to-end workflows
- Real-world patterns

**[checklist.md](references/checklist.md)** - Implementation checklist:
- Setup tasks
- Feature development workflow
- Production deployment steps

## Core Principles

1. **Actions contain domain logic** - Business logic lives in invokable action classes
2. **Never pass primitives** - Always use DTOs for data transfer
3. **Thin HTTP layer** - Controllers only handle HTTP concerns
4. **Custom query builders** - Type-safe queries over scopes
5. **Strict typing** - `declare(strict_types=1)` in every file

## Quick Decision Tree

Need to...
- **Handle domain logic?** → Action
- **Transfer data?** → DTO
- **Validate user input?** → Form Request
- **Simple state field?** → Enum
- **Complex state transitions?** → State Machine
- **External API?** → Service with Saloon
- **Background processing?** → Job (delegates to Action)

Read decision flowcharts in **[decisions.md](references/decisions.md)** for detailed guidance.

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [leeovery](https://github.com/leeovery)
- **Source:** [leeovery/agentic-skills](https://github.com/leeovery/agentic-skills)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-leeovery-agentic-skills-laravel-architecture
- Seller: https://agentstack.voostack.com/s/leeovery
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
