# charlesacioli1/restaurante architecture

> Architecture diagram of the GitHub repository charlesacioli1/restaurante, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-30). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/charlesacioli1/restaurante
- Repository: https://github.com/charlesacioli1/restaurante

## Overview

This is a restaurant-management backend organized around a restaurant CRUD service and a persisted domain model. In the sampled implementation, the service accepts restaurant DTOs, creates or updates domain entities, and reads or writes them through Entity Framework. The domain also models menus, kitchen stations, staff, tables, orders, queues, and status values; these are represented as capabilities, not as a demonstrated end-to-end operational workflow. The README is empty, and the excerpts do not establish how the presentation layer routes requests.

Main entry points: [`src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs) (Entity Framework context), [`src/Restaurante.Services/Implementations/RestauranteService.cs`](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/Implementations/RestauranteService.cs) (Restaurant CRUD), [`src/Restaurante.Presentation/Program.cs`](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Presentation/Program.cs) (Presentation host), [`src/Restaurante.Domain/Restaurante.cs`](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Restaurante.cs) (Restaurant entity)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_service["Restaurant service"]
  node_restaurant_service["Restaurant CRUD"]
  node_service_contract["Service contract"]
  node_create_dto["Create input"]
  node_update_dto["Update input"]
  node_response_dto["Restaurant response"]
end

subgraph group_domain["Restaurant domain"]
  node_restaurant["Restaurant entity<br/>[Restaurante.cs]"]
  node_menu["Menus and items<br/>[Cardapio.cs]"]
  node_kitchen["Kitchen and queue<br/>[Cozinha.cs]"]
  node_staff["Waiters and assignments"]
  node_tables_orders["Tables and orders<br/>[Pedido.cs]"]
  node_statuses["Domain statuses<br/>[StatusPedido.cs]"]
end

subgraph group_persistence["Persistence"]
  node_db_context["Entity Framework context"]
  node_configurations["Entity mappings<br/>[Configurations]"]
end

node_caller(("API caller"))
node_presentation["Presentation host<br/>[Program.cs]"]
node_database[("Relational database")]

node_restaurant_service -->|"reads and writes"| node_db_context
node_restaurant_service -->|"creates and updates"| node_restaurant
node_restaurant_service -->|"accepts"| node_create_dto
node_restaurant_service -->|"accepts"| node_update_dto
node_restaurant_service -->|"returns"| node_response_dto
node_db_context -->|"tracks"| node_restaurant
node_db_context -->|"tracks"| node_menu
node_db_context -->|"tracks"| node_kitchen
node_db_context -->|"tracks"| node_staff
node_db_context -->|"tracks"| node_tables_orders
node_db_context -->|"tracks"| node_statuses
node_db_context -->|"applies mappings"| node_configurations
node_db_context -.->|"persists entities"| node_database
node_caller -.->|"sends requests"| node_presentation
node_presentation -.->|"dispatches to"| node_restaurant_service

click node_presentation "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Presentation/Program.cs"
click node_restaurant_service "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/Implementations/RestauranteService.cs"
click node_service_contract "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/Interfaces/IRestauranteService.cs"
click node_create_dto "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/DTOs/Restaurante/CriarRestauranteDto.cs"
click node_update_dto "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/DTOs/Restaurante/AtualizarRestauranteDto.cs"
click node_response_dto "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/DTOs/Restaurante/RestauranteResponseDto.cs"
click node_restaurant "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Restaurante.cs"
click node_menu "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Cardapio.cs"
click node_kitchen "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Cozinha.cs"
click node_staff "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/GarcomRestaurante.cs"
click node_tables_orders "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Pedido.cs"
click node_statuses "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/StatusPedido.cs"
click node_db_context "https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs"
click node_configurations "https://github.com/charlesacioli1/restaurante/tree/master/src/Restaurante.Infrastructure/Configurations"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_restaurant_service,node_service_contract,node_create_dto,node_update_dto,node_response_dto toneBlue
class node_restaurant,node_menu,node_kitchen,node_staff,node_tables_orders,node_statuses,node_database toneAmber
class node_db_context,node_configurations,node_caller toneMint
class node_presentation toneTeal
```

## Components

### Restaurant service

- [Restaurant CRUD](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/Implementations/RestauranteService.cs): `src/Restaurante.Services/Implementations/RestauranteService.cs`
- [Service contract](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/Interfaces/IRestauranteService.cs): `src/Restaurante.Services/Interfaces/IRestauranteService.cs`
- [Create input](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/DTOs/Restaurante/CriarRestauranteDto.cs): `src/Restaurante.Services/DTOs/Restaurante/CriarRestauranteDto.cs`
- [Update input](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/DTOs/Restaurante/AtualizarRestauranteDto.cs): `src/Restaurante.Services/DTOs/Restaurante/AtualizarRestauranteDto.cs`
- [Restaurant response](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Services/DTOs/Restaurante/RestauranteResponseDto.cs): `src/Restaurante.Services/DTOs/Restaurante/RestauranteResponseDto.cs`

### Restaurant domain

- [Restaurant entity](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Restaurante.cs): `src/Restaurante.Domain/Restaurante.cs`
- [Menus and items](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Cardapio.cs): `src/Restaurante.Domain/Cardapio.cs`
- [Kitchen and queue](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Cozinha.cs): `src/Restaurante.Domain/Cozinha.cs`
- [Waiters and assignments](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/GarcomRestaurante.cs): `src/Restaurante.Domain/GarcomRestaurante.cs`
- [Tables and orders](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/Pedido.cs): `src/Restaurante.Domain/Pedido.cs`
- [Domain statuses](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Domain/StatusPedido.cs): `src/Restaurante.Domain/StatusPedido.cs`

### Persistence

- [Entity Framework context](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs): `src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`
- [Entity mappings](https://github.com/charlesacioli1/restaurante/tree/master/src/Restaurante.Infrastructure/Configurations): `src/Restaurante.Infrastructure/Configurations`

### Other components

- **API caller**
- [Presentation host](https://github.com/charlesacioli1/restaurante/blob/master/src/Restaurante.Presentation/Program.cs): `src/Restaurante.Presentation/Program.cs`
- **Relational database**

## Connections

- Restaurant CRUD → Entity Framework context: reads and writes (evidence: `src/Restaurante.Services/Implementations/RestauranteService.cs`)
- Restaurant CRUD → Restaurant entity: creates and updates (evidence: `src/Restaurante.Services/Implementations/RestauranteService.cs`)
- Restaurant CRUD → Create input: accepts (evidence: `src/Restaurante.Services/Implementations/RestauranteService.cs`)
- Restaurant CRUD → Update input: accepts (evidence: `src/Restaurante.Services/Implementations/RestauranteService.cs`)
- Restaurant CRUD → Restaurant response: returns (evidence: `src/Restaurante.Services/Implementations/RestauranteService.cs`)
- Entity Framework context → Restaurant entity: tracks (evidence: `src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`)
- Entity Framework context → Menus and items: tracks (evidence: `src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`)
- Entity Framework context → Kitchen and queue: tracks (evidence: `src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`)
- Entity Framework context → Waiters and assignments: tracks (evidence: `src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`)
- Entity Framework context → Tables and orders: tracks (evidence: `src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`)
- Entity Framework context → Domain statuses: tracks (evidence: `src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`)
- Entity Framework context → Entity mappings: applies mappings (evidence: `src/Restaurante.Infrastructure/Persistencia/RestauranteDbContext.cs`)
- Entity Framework context → Relational database: persists entities
- API caller → Presentation host: sends requests
- Presentation host → Restaurant CRUD: dispatches to
