{"id":37373283,"url":"https://github.com/soulcodex/fastapi-ddd-atlantica-workshop","last_synced_at":"2026-01-16T05:01:09.352Z","repository":{"id":181636966,"uuid":"667074301","full_name":"soulcodex/fastapi-ddd-atlantica-workshop","owner":"soulcodex","description":"Domain Driven Design on FastAPI by Python Coruña - Workshop","archived":false,"fork":false,"pushed_at":"2023-09-24T18:28:34.000Z","size":222,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2023-09-24T19:46:23.247Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/soulcodex.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-07-16T14:58:00.000Z","updated_at":"2023-09-23T11:39:37.000Z","dependencies_parsed_at":"2023-07-16T17:16:03.793Z","dependency_job_id":null,"html_url":"https://github.com/soulcodex/fastapi-ddd-atlantica-workshop","commit_stats":null,"previous_names":["soulcodex/fastapi-ddd-atlantica-workshop"],"tags_count":0,"template":null,"template_full_name":null,"purl":"pkg:github/soulcodex/fastapi-ddd-atlantica-workshop","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soulcodex%2Ffastapi-ddd-atlantica-workshop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soulcodex%2Ffastapi-ddd-atlantica-workshop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soulcodex%2Ffastapi-ddd-atlantica-workshop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soulcodex%2Ffastapi-ddd-atlantica-workshop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/soulcodex","download_url":"https://codeload.github.com/soulcodex/fastapi-ddd-atlantica-workshop/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/soulcodex%2Ffastapi-ddd-atlantica-workshop/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28477210,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T03:13:13.607Z","status":"ssl_error","status_checked_at":"2026-01-16T03:11:47.863Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-01-16T05:01:02.058Z","updated_at":"2026-01-16T05:01:09.340Z","avatar_url":"https://github.com/soulcodex.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 style=\"text-align: center; font-size: 3rem\" align=\"center\"\u003eDomain Driven Design on FastAPI\u003c/h1\u003e\n\u003ch6 style=\"text-align: center; font-size: 1.4rem; margin-bottom: 30px;\" align=\"center\"\u003eAtlanticaConf 2023 - UDC - Workshop\u003c/h6\u003e\n\u003cdiv align=\"center\" style=\"display: flex; gap: 5rem; align-items: center; justify-content: space-around; margin-top: 1rem\"\u003e\n  \u003cimg src=\"./.doc/assets/atlantica.png\" width=\"200\" height=\"150\" style=\"background-color: rgba(0, 42, 54, 1); padding: 25px; border: 1px solid black; border-radius: 25px;\"\u003e\n  \u003cimg src=\"./.doc/assets/fastapi.png\" width=\"150\" height=\"150\" style=\"border: 1px solid black; border-radius: 4px; object-fit: cover;\"\u003e\n  \u003cimg src=\"./.doc/assets/ddd.png\" width=\"150\" height=\"150\" style=\"background-color: rgba(0, 42, 54, 1); padding: 25px; border: 1px solid black; border-radius: 25px;\"\u003e\n\u003c/div\u003e\n\u003ch6 style=\"text-align: center; font-size: 2rem\" align=\"center\"\u003eby Python Coruña\u003c/h6\u003e\n\n## Slides\n\nThere are available some [slides](https://bit.ly/fastapi-atlanticaconf-2023-slides) to get more context about the workshop and to be used as source of information as much you want as well. \n\n_**NOTE:** Thanks for your attendance to the workshop :heart:, I really enjoyed doing all this stuff, sharing some knowledge and good time_.\n\n## Introduction :writing_hand:\n\nWelcome dear coder to the official repository for the tech talk series called **\"FastAPI from Zero to Hero\"**.\n\nMy name is **Roberto García** and I really hope you can enjoy these resources to keep growing in your career path as a\npython programmer specifically developing **REST APIs** using **FastAPI** as a framework.\n\nWe are in the second phase called **\"Domain Driven Design on FastAPI\"**, now we should do our first steps together towards a event driven architecture, apply our\nprevious knowledge about all the good things that **FastAPI** provide us out-of-box, take the steering wheel of our\nbusiness logic in our projects and build resilient and agnostic code despite the libraries or specific technologies of\npersistence, messaging, cache, identifiers, time and so on.\n\n___\n\n## Requirements :bullettrain_side:\n\n* Python \u003e= 3.8\n* docker\n* Starving for knowledge (The most important :smile:)\n___\n## Getting started :checkered_flag:\n\n```bash\n# Clone the repository\ngit clone https://github.com/soulcodex/fastapi-ddd-atlantica-workshop.git shoes-store-api\n\n# Setup the repository\ncd shoes-store-api\nmake shoes-api\nmake shoes-api-bash\n```\n___\n## Available commands :running: :fire:\n\n* Run the `make help` command to get a list of all available commands\n\n```text\nshoes-api                      Setup shoes api dependencies.\nshoes-api-bash                 Open a new bash terminal inside shoes-api container.\nshoes-api-docker-stop          Down docker containers related with the shoes service.\nshoes-api-package-add          Add package to our shoes api deps.\nshoes-api-package-remove       Remove package from our shoes api deps.\nshoes-api-unit-test            Run unitary tests suite for shoes application.\nshoes-api-acceptance-test      Run acceptance tests suite for shoes application.\n```\n___\n\n## Project folders structure :file_folder:\n\n```text\n.\n├── apps\n│   └── shoes\n│       ├── dependency_injection\n│       ├── docker\n│       ├── migrations\n│       ├── routes\n│       └── ui\n├── shared\n│   ├── domain\n│   │   ├── bus\n│   │   └── types\n│   └── infrastructure\n│       ├── mysql\n│       └── pytest\n├── shoes\n│   ├── application\n│   ├── domain\n│   └── infrastructure\n│       ├── persistence\n│       └── pytest\n└── tests\n    └── shoes\n```\n\n### apps :open_file_folder: :arrow_double_down:\n\n* Basically is the folder to define all the entrypoints for those applications which live in this repository\n  following a monorepo structure.\n* Defines dependency injection graph and bootstrap it all of them.\n* Framework entrypoints and all the most external things which needs pieces which comes from the framework (routers,\n  middlewares, pydantic models, etc...)\n* Docker :whale: things (development or deployment things related with Docker)\n* Database migration files on each bounded context folders.\n\n### shoes == module == bounded context :open_file_folder: :shoe:\n\n* application :open_file_folder: :arrow_up: :arrow_down:\n    * Application use cases, interaction between the domain and infrastructure driven by the query and command bus.\n        * For 1 query exist one query handler and the same for commands (query -\u003e read operations, command -\u003e write\n          operations).\n        * Application services which supports the query and command handlers (Rarely needed but that's the correct\n          place).\n        * Unitary tests which validates the handler's logic.\n* domain :open_file_folder: :european_castle:\n    * In this layer we should put all the related with data model definition which match with the real world\n      representation, in this case the root model is `Shoe`.\n    * Domain services implementations or ports interfaces (no implementations just definitions AKA abstract method\n      classes).\n    * Value objects which help us to validate the integrity of the data in a bidirectional way (api -\u003e database or\n      database -\u003e api).\n* infrastructure :open_file_folder: :mag: :office:\n    * Database connections (database pool, single reader, reader and writer).\n    * Cache adapters (Redis, Elastic cache, Key value database etc..).\n    * Repositories implementations (MySQL, MS SQL Server, PostgreSQL, Elasticsearch, Redis, MongoDB, etc...).\n    * Messaging system connection and publishers (SNS, SQS, RabbitMQ, Kafka, Red Panda, etc...).\n    * Identifiers generation (UUID and ULID generator library implementation).\n    * Time providers (Provider which generate new instances of objects in charge to handle the time.).\n    * and so on.\n\n### shared :open_file_folder: :twisted_rightwards_arrows:\n\n* domain :open_file_folder: :european_castle:\n    * Shared logic of domain definitions and ports (Query bus, Command bus, Value objects parents).\n    * Domain errors base definitions and severities.\n* infrastructure :open_file_folder: :mag: :office:\n    * Shared logic to implement infrastructure components\n        * Base repositories implementations or infrastructure interfaces.\n        * Database connection pools and helpers.\n        * Providers (time, identifiers and so on).\n        * Test library shared implementations across all bounded contexts.\n        * Shared middlewares or something specific to use with the framework.\n        * Pydantic base implementations and models.\n\n### tests :open_file_folder: :gem:\n\n* Acceptance tests (HTTP calls, E2E, validate input and output with all the actors)\n    * Typology of test in charge to validate how our components works together validating if the code / app do the\n      expected behavior or not.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsoulcodex%2Ffastapi-ddd-atlantica-workshop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsoulcodex%2Ffastapi-ddd-atlantica-workshop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsoulcodex%2Ffastapi-ddd-atlantica-workshop/lists"}