{"id":20213509,"url":"https://github.com/thadeshammer/boilerplate-sqlalch-fastapi","last_synced_at":"2026-04-08T20:45:16.439Z","repository":{"id":240557725,"uuid":"802957714","full_name":"thadeshammer/boilerplate-sqlalch-fastapi","owner":"thadeshammer","description":"A light skeleton to get you up and moving with SQLAlchemy and FastAPI. Uses Docker. Features a small SlowAPI example as well.","archived":false,"fork":false,"pushed_at":"2024-05-19T23:39:14.000Z","size":17,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-08-19T02:50:47.325Z","etag":null,"topics":["docker","fastapi","postgres","python","slowapi","sqlalchemy","uvicorn"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thadeshammer.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-05-19T17:59:10.000Z","updated_at":"2024-05-19T23:39:17.000Z","dependencies_parsed_at":"2025-01-13T21:41:35.468Z","dependency_job_id":"0219755b-b6e7-4da1-924a-a673f1aed88c","html_url":"https://github.com/thadeshammer/boilerplate-sqlalch-fastapi","commit_stats":null,"previous_names":["thadeshammer/boilerplate-sqlalch-fastapi"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/thadeshammer/boilerplate-sqlalch-fastapi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thadeshammer%2Fboilerplate-sqlalch-fastapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thadeshammer%2Fboilerplate-sqlalch-fastapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thadeshammer%2Fboilerplate-sqlalch-fastapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thadeshammer%2Fboilerplate-sqlalch-fastapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thadeshammer","download_url":"https://codeload.github.com/thadeshammer/boilerplate-sqlalch-fastapi/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thadeshammer%2Fboilerplate-sqlalch-fastapi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31573788,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-08T14:31:17.711Z","status":"ssl_error","status_checked_at":"2026-04-08T14:31:17.202Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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":["docker","fastapi","postgres","python","slowapi","sqlalchemy","uvicorn"],"created_at":"2024-11-14T06:09:39.988Z","updated_at":"2026-04-08T20:45:16.412Z","avatar_url":"https://github.com/thadeshammer.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Boilerplate Python for FastAPI and SQLAlchemy\n\nA simplistic and thoroughly commented example to get you up and moving with minimal fuss. There's a SlowAPI rate-limiting example you can trim out if you don't need it.\n\n## Quick Start\n\nClone, start docker, and run:\n```\ndocker-compose build \u0026\u0026 docker-compose up\n```\nThen open up the Swagger UI via `localhost/docs`\n\nThere are only three VERY simple endpoints in this example.\n\n* `/` the root just returns 'Ready.' if it did in fact start okay.\n* `/addname` takes a string 'name' and sticks it into the DB along with a generated UUID.\n* `/getnames` will spit out everything in that table.\n\n**NOTE the DB is not persisted outside of its container** so if you destroy/rebuild the container, that data is gone. If you don't want that, you'll need to mount a volume for it.\n\n## What's Inside\n\n### Docker\n\n**DB** This example uses postgres but I also tested it against mysql and sqlite3.\n\n**SERVER** FastAPI on uvicorn, see `requirements.txt` for libraries you'll need. Runs on port 80.\n\n### Python\n\nI'm using 3.11 in this example, but since FastAPI has a dependency on `wheel`, you might find that your IDE (looking at you VSCode) will always be unhappy with FastAPI; this is because - I've learned - the maintainers of wheel deprioritize Windows. (Personally, I don't blame them, but it is a factor.) Since the app itself runs dockerized, it will work. You just have to deal with the red squigglies.\n\n* **fastapi** run on uvicorn with hot-reload.\n* **slowapi** with a simplistic example of rate-limiting\n* **sqlalchemy** ORM with:\n * a test model that creates an associated table in the db if it doesn't exist.\n * bare minimum setup to get python and the db talking\n* **pydantic** for the SQLAlchemy to FastAPI communication. (I learned about SQLModel later.)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthadeshammer%2Fboilerplate-sqlalch-fastapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthadeshammer%2Fboilerplate-sqlalch-fastapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthadeshammer%2Fboilerplate-sqlalch-fastapi/lists"}