Add your description here
Project description
FastAPI Freelance Backend Template
This repository is a reusable FastAPI backend template for a freelancing platform. It includes:
- FastAPI with async endpoints
- PostgreSQL with SQLAlchemy 2.0 async sessions
- JWT authentication for users
- A
fastapi-readyCLI to scaffold new projects from this template - GitHub Actions workflows for CI and PyPI publishing with OIDC trusted publishing
Quick Start
Install the template command with pip:
python -m pip install .
Install dependencies:
uv sync
Run the app:
uvicorn main:app --reload
Create a New Project
After installing this package, generate a fresh project from the template:
fastapi-ready my-new-app
cd my-new-app
uv sync
uvicorn main:app --reload
Environment Variables
Create a .env file in the project root:
DATABASE_URL=postgresql+asyncpg://postgres:root@localhost:5432/users
SECRET_KEY=your-secret-key
ACCESS_TOKEN_EXPIRE_MINUTES=60
SQL_ECHO=False
JWT_ALGORITHM=HS256
CI
The repository includes a GitHub Actions workflow that installs dependencies and runs checks on every push and pull request.
CD to PyPI
Publishing uses GitHub Actions OpenID Connect trusted publishing through PyPI.
When configuring the PyPI trusted publisher, use these values:
- PyPI project name:
project name - Owner:
owner - Repository name:
repository - Workflow name:
workflow.yml - Environment name:
pypi
The publishing workflow lives at .github/workflows/workflow.yml.
Files
.github/workflows/ci.yml- test workflow.github/workflows/workflow.yml- PyPI publish workflow
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fastapi_ready-0.1.0.tar.gz.
File metadata
- Download URL: fastapi_ready-0.1.0.tar.gz
- Upload date:
- Size: 5.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c63ab7c11f201f2e6796c8d8156183f67685c15d16462676a899ff95d8ac2f4e
|
|
| MD5 |
2eb5ab326c6a7ef16febdaf0041e526d
|
|
| BLAKE2b-256 |
6c993b956aaeea84583c515462d3d985f099c7f8b0e6bf79f4cb6eb0dc3a6314
|
Provenance
The following attestation bundles were made for fastapi_ready-0.1.0.tar.gz:
Publisher:
workflow.yml on Sachinn-p/fastapi-ready
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
fastapi_ready-0.1.0.tar.gz -
Subject digest:
c63ab7c11f201f2e6796c8d8156183f67685c15d16462676a899ff95d8ac2f4e - Sigstore transparency entry: 1358402546
- Sigstore integration time:
-
Permalink:
Sachinn-p/fastapi-ready@8558c569285cf1d52f763c293477e63ee69e0145 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/Sachinn-p
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
workflow.yml@8558c569285cf1d52f763c293477e63ee69e0145 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file fastapi_ready-0.1.0-py3-none-any.whl.
File metadata
- Download URL: fastapi_ready-0.1.0-py3-none-any.whl
- Upload date:
- Size: 6.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
691d95be16b04cfce7dbd87bfb5ebc32dfaa001b3853b60ce3f410a53636abec
|
|
| MD5 |
97e73283a6fad5cf1ba6cf488f0b8853
|
|
| BLAKE2b-256 |
697f82bb23529a8bde3fad857daed46501cbf1b7c118615d20f006e78f388f0d
|
Provenance
The following attestation bundles were made for fastapi_ready-0.1.0-py3-none-any.whl:
Publisher:
workflow.yml on Sachinn-p/fastapi-ready
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
fastapi_ready-0.1.0-py3-none-any.whl -
Subject digest:
691d95be16b04cfce7dbd87bfb5ebc32dfaa001b3853b60ce3f410a53636abec - Sigstore transparency entry: 1358402567
- Sigstore integration time:
-
Permalink:
Sachinn-p/fastapi-ready@8558c569285cf1d52f763c293477e63ee69e0145 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/Sachinn-p
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
workflow.yml@8558c569285cf1d52f763c293477e63ee69e0145 -
Trigger Event:
workflow_dispatch
-
Statement type: