> For the complete documentation index, see [llms.txt](https://note.levelcode.org/software-engineering-notes/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://note.levelcode.org/software-engineering-notes/readme/5-layers/7-application-layer.md).

# Application Layer

### Application Service

* Defines the use case for the system
* Receives request from infra layer and coordinate the use of objects from domain layer and other layer

#### Note

* Application service operations can be represented by method (inside object) or function, using function is great if you're not planning to make the service stateful

### Data Transfer Object (DTO)

* Used to transfer data between application layer and infrastructure layer
* Should only contain data
* Should not contain behaviour
* Can be mutable or immutable, make it mutable only if it needs to be modified on transfer
