Skip to content
Skills Library
Programming · Learning & explanation

stack-backend

/stack-backend

Backend conventions for the FastAPI + React stack (app/, Python 3.12, FastAPI, uv, pytest). Use when creating or changing endpoints, services, schemas, tests or Python dependencies.

Licence
MIT
Last repository change
27.10.2026

Assessment and security

91/ 100Class: good
Format25 / 25
Frontmatter with name and description, valid name, description up to 1,024 characters, name matching the folder.
Discoverability25 / 25
Description explains when to use the skill, has a reasonable length and uses third person.
Content26 / 35
At least 150 words and at most 500 lines, headings, step lists, examples or code.
Hygiene15 / 15
No placeholders such as TODO, no Windows paths, with a licence.
Riskno signals detected in the scan
Files in this package
1
Scripts
0
HTML comments
0
URLs in SKILL.md
0
Deprecation

No signals detected. Repository changed on 27.10.2026, without references to retired models or APIs.

Licence

MIT, open: use and modify while retaining author attribution.

What it does and when to use it

Backend conventions for the FastAPI + React stack (app/, Python 3.12, FastAPI, uv, pytest). Use when creating or changing endpoints, services, schemas, tests or Python dependencies.

Original author description

Backend conventions for the FastAPI + React stack (app/, Python 3.12, FastAPI, uv, pytest). Use when creating or changing endpoints, services, schemas, tests or Python dependencies.

How it works

SKILL.md has no level-two headings · 30 lines, 263 words

SKILL.md preview
---
name: stack-backend
description: Backend conventions for the FastAPI + React stack (app/, Python 3.12, FastAPI, uv, pytest). Use when creating or changing endpoints, services, schemas, tests or Python dependencies.
---
# Backend · FastAPI + React stack
Initial setup: `.uak/stacks/fastapi-react/STACK.md`. This file holds only the conventions for parallel work.

```text
app/main.py             # auto-discovers routers, serves web/dist; nobody edits it after setup
app/config.py           # settings from env (pydantic-settings); owner: setup
app/schemas/            # shared Pydantic contracts; single owner (contract task)
app/fixtures/           # labeled demo data
app/routers/<f>.py      # router = APIRouter(prefix="/api/<f>", tags=["<f>"])
app/services/<f>.py     # logic; external calls with timeout + mock fallback
app/tests/test_<f>.py   # TestClient: happy path + one error
```

| Rule | Why |
|---|---|
| Every route lives under `/api/...` | One prefix for the frontend; FastAPI serves the web at `/`. |
| A task reserves `app/routers/<f>.py, app/services/<f>.py, app/tests/test_<f>.py` (+ `web/src/features/<f>/`) | Disjoint claims. |
| Read schemas from `app/schemas/`; ask their owner for changes (`--kind request`) | One writer per contract. |
| External calls only in `services/`, with `httpx` and a `timeout=`; fall back to a mock on `DEMO_MODE=true` or failure | The demo survives a dead API. |
| Mocks carry `"demo_data": true` | Mocks are always labeled. |
| New deps: ask the owner of `pyproject.toml`/`uv.lock` | Auto-merge rejects lockfile changes. |
| `zoneinfo.ZoneInfo(...)` needs `tzdata` in `pyproject.toml` (setup adds it) | Windows has no time zone database: the app failed to import on a Windows laptop, and the fix had to wait for the lockfile owner. |
| Secrets come only from env via `app/config.py` | The pre-commit scanner blocks them. |

```bash
bash .uak/bin/q uv run pytest -q --tb=short -x app/tests/test_<f>.py
bash .uak/bin/q uv run ruff check app
uv run uvicorn app.main:app --reload --port "${UAK_PORT:-8000}"
```

Versions

The database has no other skills named stack-backend.

Database snapshot: 13.11.2026 · package version e06ca7eec7ea (SHA-256 digest of the entire package)

Downloads in the last 30 days: 0 · ranking

Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.

Similar skills

  • 100fastapi-patterns
    Build and review FastAPI services. Covers project layout, app factory and lifespan, pydantic-settings config, Pydantic v2 schemas, Annotated dependencies, thin routers over a service layer, async database sessions, auth (401 vs 403), error handlers and tests with httpx and…
  • 86Backend Python Expert
    当用户需要进行 Python 后端开发时使用。此 Skill 提供 FastAPI 开发、异步编程和性能优化等 Python 后端开发全栈能力支持。
  • 96stack-frontend
    Frontend conventions for the FastAPI + React stack (web/, Vite, React, TypeScript, Tailwind v4, Motion). Use when creating or changing any screen, component or style in web/, deciding visual design, or verifying UI in a browser.
  • 86python-fastapi-apps
    Use when building or extending a Python FastAPI web app.
  • 100testing-conventions
    Testing conventions for Python/FastAPI and React — pytest, async fixtures, AsyncMock, Vitest, and security-regression tests (authz, tenant isolation). Do NOT use for the TDD loop (use test-driven-development).
  • 90python-backend
    Build and upgrade Python services with explicit environments, validation, async boundaries and resource cleanup. Use when working on FastAPI, Django or Python API/jobs; preserve the project framework and packaging workflow.

Feedback and reports

Your message goes to Bartosz Sokoliński. An email address is needed only for a reply. See the privacy policy.