Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/kodexarg-k-django-6-drf
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: frontend, backend, testing, devops
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/k-django-6-drf
What's inside
- Skill name
k-django-6-drf- Description
- Opinionated Django 6 + DRF backend entrypoint. Use when the user invokes k-django-6-drf, or works on Django/DRF models, viewsets, serializers, HTMX HTML fragments, migrations, pytest for the API, local Postgres-in-Docker, or ECS Fargate + RDS Postgres. Django 6 only — no older majors, no retrocompat shims.
- License
- MIT
- Metadata
- version: 6.1b1 · pins_ssot: docs/REQUIREMENTS.md · docs_as_of: 2026-07-10 · template_ref: this checkout
- Instructions
- 160 lines in SKILL.md · view on GitHub
Files (2)
- SKILL.md
- patterns.md · references/
SKILL.md (first lines)
> [!info] In force on this repo (Team Party map)
> Layout [[adr-25-harness-layout]]: project stack skill (stem names the pinned stack taught).
> Product SSOT: `docs/constitution/PRD.md`. Canonical host: `{{PUBLIC_HOST}}`.
> Citations: [[adr-24-constitution]], [[adr-25-harness-layout]], [[adr-27-guardians-and-delivery]].
> Live AWS names that still contain `astro-drf-aws` are leftover until Gabriel reprovisions — do not invent ARNs.
# k-django-6-drf
**Swiss-army Django API skill.** Trigger on `k-django-6-drf` or any Django/DRF backend work for kodex projects. Always assume this stack; do not invent alternatives.
## Fixed stack (no retrocompat)
| Layer | Choice |
|-------|--------|
| Framework | **Django 6.1b1** (template pin); fallback **6.0.7** stable if beta blocks — never invent a third number |
| API | **DRF** viewsets + routers (plain `APIView` only when a viewset does not fit) |
| OpenAPI | **drf-spectacular** (schema is derivative; `docs/API.md` is SSOT) |
| DB | **PostgreSQL 17.9** via **psycopg 3** — never SQLite for app data |
| Toolchain | **`uv` only** — never `pip` / poetry / pipenv |
| Server | **ASGI** on port **8000** (gunicorn+uvicorn workers or uvicorn; pin in REQUIREMENTS) |
| Cache | **`DatabaseCache`** (+ optional `LocMemCache` alias). **Redis / ElastiCache forbidden** |
| Tasks | **`django.tasks`** first. Celery only if the user explicitly demands it |
| Hypermedia | **HTMX fragments** — Django templates/`TemplateResponse` are the HTML producer; Astro only loads the client (`docs/HTMX.md`) |
| Frontend pair | Astro 7 SSR → skill `k-astro-7` (attributes + shell; not fragment HTML) |
**Pin SSOT:** project `docs/REQUIREMENTS.md` (this repo). Metadata above mirrors that file — on re-pin, update REQUIREMENTS first, then this frontmatter. Prefer live PyPI / Django docs when versions drift mid-session. **Never** support Django ≤5.
## Only two runtimes
| Target | Database | How code differs |
|--------|----------|------------------|
| **Local** | Postgres 17 in Docker (or native 17) | Same app code; only env (`DB_*` vars, secrets) changes |
| **AWS** | RDS Postgres 17 + **ECS Fargate** task | Same app code; secrets from Secrets Manager; ASGI :8000 behind ALB |
Code **must not** branch on environment names. Settings are **fully env-driven** — no `settings/dev.py` / `settings/prod.py` splits.
Template infra SSOT: `docs/` (`BACKEND`, `HTMX`, `BD`, `API`, `TDD`, `CACHE`, `INFRASTRUCTURE`, `VARIABLES`, `REQUIREMENTS`).
## Forbidden (reject unless user overrides in-turn)
- Django 5.x / 4.x patterns, LTS “support matrices”, version-gated shims
- `CheckConstraint(check=…)` → use **`condition=`** (Django 5.1+; required on 6)
- `DEFAULT_FILE_STORAGE` / `STATICFILES_STORAGE` → use **`STORAGES`**
- `django-csp` as primary CSP → use **`ContentSecurityPolicyMiddleware` + `SECURE_CSP`**
- `SECURE_BROWSER_XSS_FILTER` cargo-cult (browsers ignore it)
- Redis / ElastiCache / celery-as-default
- `pip install`, requirements.txt-only workflows when `uv` is available
- JSON:API / Prowler-style multi-tenant RLS scaffolding (not our default)
- `trailing_slash=False` (we keep **trailing slashes**)
- `fields = "__all__"` / `exclude = …` on serializers
- Business logic in serializers or views (use services / model methods / managers)
- Routes not declared in `docs/API.md`
- Domain HTML fragments rendered by Astro/Svelte for HTMX swaps (Django owns fragment HTML)
- Returning JSON from a route that HTMX is expected to swap without an explicit dual-contract design
- Manual SQL schema / non-Django migration tools
- Non-English comments, docstrings, or log messages ([[LOCALIZATION]])
## Non-negotiables
1. **English only** in code, identifiers, comments, and docstrings ([[LOCALIZATION]]). Prefer no comments (KISS); never non-English.
2. **DRY / KISS / extreme minimal.** No dead wrappers, no “just in case”.
3. **Workflow:** `plan → docs/API.md row → TDD → models.py → rest of DRF` (JSON) or fragment views/templates. No model/endpoint without an API row.
4. **HTMX from day one** when the feature is server-owned interactive: plan partial templates, CSRF, session auth, HTML errors, and `HX-*` response headers *with* the API row — not as a retrofit. Doctrine: `docs/HTMX.md`.
5. **Single Django project**; one app per domain. No grab-bag `core`/`utils` apps.
6. **Migrations are the only schema mechanism.**
7. **ORM always** for queries; raw SQL only parameterized and justified.
8. **Secrets:** env locally (gitignored); **AWS Secrets Manager** on Fargate. Never commit secrets.
9. **Authenticated responses** default `Cache-Control: no-store` unless the API row says otherwise.
## Django 6 — use these, not the old thing
| Do | Don’t |
|----|--------|
| `CheckConstraint(condition=Q(…), name="…")` | `check=` |
| `STORAGES = {"default": …, "staticfiles": …}` | `DEFAULT_FILE_STORAGE` / `STATICFILES_STORAGE` |
| `SECURE_CSP` + `ContentSecurityPolicyMiddleware` | third-party CSP middleware as default |
| `@task` / `django.tasks` backends | Celery by reflex |
| `GeneratedField` / `db_default` when useful | always-compute-in-Python columns |
| Python **3.14.6** (REQUIREMENTS pin) | Python 3.10–3.13 “because it still works” |
## DRF doctrine (ultra-short)
Load recipes: `references/patterns.md`.
| Rule | Detail |
|------|--------|
| Serializers | **Split by action:** `XSerializer` (read), `XCreateSerializer`, `XUpdateSerializer` |
| Fields | Explicit whitelist only; system fields `read_only` |
| ViewSets | Default; `get_queryset()` always applies `select_related` / `prefetch_related` |
| spectacular | Guard `if getattr(self, "swagger_fake_view", False): return qs.none()` |
| Filters | `filterset_class` for anything non-trivial (not only `filterset_fields`) |
| Permissions | Class on the viewset; object-level when ownership matters |
| OpenAPI | `@extend_schema_view` / `@extend_schema_field` on method fields |
| Errors | Generic messages; prefer 404 over 403 when it prevents enumeration |
| Prefixes | Backend paths under `/api/`, `/admin/`, `/accounts/`, `/ws/` only |
| HTMX | Fragment routes return `text/html`; serializers column is `—` in API.md; tests assert status + key markup |
## HTMX fragments (Django produces HTML)
HTMX is in the stack **because this backend exists**. Design fragment support when the feature needs server-owned UI — same cycle as any endpoint.
| Do | Don’t |
|----|--------|
| `TemplateResponse` + app templates | Expect Astro to emit domain swap HTML |
| Separate API.md rows for JSON vs HTML | One JSON view “also used” as HTMX without a row |
| CSRF + session for mutating `hx-*` | Token-only SPA defaults for browser forms |
| HTML validation / permission error fragments | Bare JSON error body for HTMX targets |
| Stable element ids matching `hx-target` | Ad-hoc ids only in the frontend shell |
| Outbound `HX-Trigger` / `HX-Redirect` / … when needed | Silent full-page assumptions |
Recipes: `references/patterns.md` → section HTMX.
## Layout (default)
```
config/ # project package: settings.py, urls.py, asgi.py
apps/<domain>/ # models, serializers, views, urls, services, tests
apps/<domain>/templates/<domain>/ # HTMX partials live with the domainFrom kodexArg/astro-drf-aws, MIT.
More from kodexArg/astro-drf-aws
- 0.529score
k-report
kodexArg
CONVERT a given markdown summary (prose, lists, code, ```mermaid blocks) into ONE self-contained, opinionated, mobile-first (and desktop-friendly) dark HTML…
SkillBFreshness: BClaude Code +9 - 0.529score
k-astro-7
kodexArg
Opinionated frontend entrypoint for Astro 7 + Svelte 5 + HTMX.
SkillBFreshness: BClaude Code +9 - 0.524score
k-role-party
kodexArg
Grok Role Party — multi-issue orchestrator that runs the Hunter → Mage → Warrior/Archer party against open GitHub issues, prioritizes easy→hard, opens one PR…
SkillBFreshness: BClaude Code +9 - 0.524score
k-assertion-review
kodexArg
Enforce assertion laws: interpret each promise, require proving tests via TDD.md, drive the fix or feature until tests hold, set verified.
SkillBFreshness: BClaude Code +9 - 0.524score
k-aws-cloudwatch-alarms
kodexArg
Minimal CloudWatch alarms for ALVS Fargate astro-drf-aws services: target health, 5xx, RDS storage.
SkillBFreshness: BClaude Code +9 - 0.524score
k-aws-cloudwatch-query
kodexArg
CloudWatch Logs Insights queries for ALVS Fargate Django and Astro services.
SkillBFreshness: BClaude Code +9 - 0.524score
k-aws-containers
kodexArg
ALVS Fargate layout for this template only: two ECS services (Django 6+DRF backend :8000, Astro 7 SSR frontend :4321), ECR, shared ALB, Cloud Map.
SkillBFreshness: BClaude Code +9 - 0.524score
k-aws-cost
kodexArg
Cost discipline for ALVS astro-drf-aws: Fargate 256/512, no NAT, no Redis, shared ALB, single-AZ micro RDS.
SkillBFreshness: BClaude Code +9 - 0.524score
k-aws-iam
kodexArg
ALVS IAM for this template: Fargate exec/task roles, GHA OIDC deploy roles, least privilege for Django/Astro on ECS.
SkillBFreshness: BClaude Code +9 - 0.524score
k-aws-secrets-create
kodexArg
Create AWS Secrets Manager secrets for astro-drf-aws on ALVS only.
SkillBFreshness: BClaude Code +9 - 0.524score
k-aws-secrets-manager
kodexArg
Operate and inject AWS Secrets Manager secrets for ALVS Fargate Django/Astro tasks.
SkillBFreshness: BClaude Code +9 - 0.524score
k-aws-troubleshoot
kodexArg
Diagnose failing ALVS Fargate Django/Astro deploys: task stops, unhealthy targets, secret injection, Cloud Map SSR calls, RDS connectivity.
SkillBFreshness: BClaude Code +9
Signals
- Stars
- 0
- Forks
- 0
- Open issues
- 4
- Last commit (this folder)
- Sep 14, 2026 (1 month ago)
From GitHub (fetched Oct 24, 2026).
Details
- Version
- 6.1b1
- License
- MIT
- Repository
- github.com/kodexArg/astro-drf-aws
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from kodexArg
- 0.529score
k-astro-7
kodexArg
Opinionated frontend entrypoint for Astro 7 + Svelte 5 + HTMX.
SkillBFreshness: BClaude Code +9 - 0.529score
k-report
kodexArg
CONVERT a given markdown summary (prose, lists, code, ```mermaid blocks) into ONE self-contained, opinionated, mobile-first (and desktop-friendly) dark HTML…
SkillBFreshness: BClaude Code +9 - 0.526score
kskill-mood
kodexArg
Slash /kdx-mood.
SkillBFreshness: BClaude Code +9 - 0.524score
hb-sk-contracts
kodexArg
Interface catalog contract for docs/INTERFACES.md: six-column row, docs/contracts/, trailing slash, declared path prefixes, fragment Payload: —.
SkillBFreshness: BClaude Code +9 - 0.524score
hb-sk-abc
kodexArg
ABC checklist: a change vs PRD, the ADRs, and INTERFACES.md.
SkillBFreshness: BClaude Code +9 - 0.524score
k-role-party
kodexArg
Grok Role Party — multi-issue orchestrator that runs the Hunter → Mage → Warrior/Archer party against open GitHub issues, prioritizes easy→hard, opens one PR…
SkillBFreshness: BClaude Code +9
Cite this page
k-django-6-drf skill. Agent Mart. https://agentmart.dev/skills/kodexarg-k-django-6-drf (last updated 2026-10-24)