Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add jiushiwon/wg-skills --skill fastapi-auth-module-skillgit clone --depth 1 https://github.com/jiushiwon/wg-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/jiushiwon/wg-skills/fastapi-auth-module-skill)<a href="https://agentmods.dev/skills/jiushiwon/wg-skills/fastapi-auth-module-skill"><img src="https://agentmods.dev/badge/skills/jiushiwon/wg-skills/fastapi-auth-module-skill/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/jiushiwon/wg-skills/fastapi-auth-module-skill"><img src="https://agentmods.dev/badge/skills/jiushiwon/wg-skills/fastapi-auth-module-skill.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00114 | $0.02058 |
| Opus 5 | $0.00057 | $0.01029 |
| Sonnet 5 | $0.00023 | $0.00412 |
| Haiku 4.5 | $0.00011 | $0.00206 |
Grade A, and why
fastapi-auth-module-skill scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 162 lines — stays where its author put it; the contents beside it link to each section on GitHub.
FastAPI Auth Module Skill
为 FastAPI 项目叠加一套企业级授权与组织架构能力,不是重新生成新项目。
定位
- 目标:在已有
fastapi-init-skill骨架上,添加可运行的 RBAC + 组织架构模块。 - 不替代:不重复生成
fastapi-init-skill已经提供的 JWT、统一响应、SQLModel 等基础设施。 - 输出:模型、仓储、服务、路由、数据库迁移、接口契约、接入指南。
骨架依赖(子模块)
本模块是
fastapi-init-skill的子模块,必须在骨架基础上使用。
使用前必须满足以下条件:
- ✅ 已安装
fastapi-init-skill(项目骨架) - ✅ 骨架包含:JWT、统一响应、SQLModel、分页、目录结构
- ✅ 遵循骨架的表前缀、字段命名、软删除规范
检测逻辑:
- 读取用户项目根目录
SKILL.md或README.md - 检测是否包含
fastapi-init-skill相关内容 - 如未检测到骨架,提示:"本模块需要先安装 fastapi-init-skill 骨架"
- 如用户拒绝安装骨架,则终止并提示无法使用
用户问题(最多 3 个)
1. 现有项目的包名是什么?(默认从 fastapi-init-skill 推断,如 app)
2. 表前缀是什么?(默认 wg)
3. 是否需要数据权限(全部 / 本部门 / 本部门及以下 / 仅本人)?(默认需要)
核心能力清单
| # | 能力 | 说明 |
|---|---|---|
| 1 | 租户(Tenant) | 多租户数据隔离,支持独立组织架构 |
| 2 | 组织架构(Org) | 树形部门,支持 parent_id 递归 |
| 3 | 岗位(Post) | 用户可绑定一个或多个岗位 |
| 4 | 用户(SysUser) | 扩展基础 User,关联租户、部门、岗位、角色 |
| 5 | 角色(Role) | RBAC 核心,支持数据权限范围 |
| 6 | 菜单/权限(Menu) | 树形菜单 + 权限标识(permission),用于前端路由与按钮级鉴权 |
| 7 | 角色-菜单绑定 | 多对多,控制角色可见菜单与接口权限 |
| 8 | 用户-角色绑定 | 多对多,一个用户可拥有多个角色 |
| 9 | 数据权限 | 按角色数据范围过滤:全部、本部门、本部门及以下、仅本人 |
| 10 | 个人鉴权 | 登录 / 登出 / 修改密码 / 当前用户详情 / 获取菜单树 |
| 11 | 接口契约 | 生成 api-contract-auth.md,与前端对齐 |
生成的模块结构
src/
├── auth/
│ ├── __init__.py
│ ├── constants.py # 权限常量
│ ├── enums.py # 数据权限枚举
│ ├── dependencies.py # 权限校验依赖
│ ├── schemas.py # Pydantic schemas
│ ├── models.py # SQLModel 模型
│ ├── routers/
│ │ ├── __init__.py
│ │ ├── auth.py # 登录 / 登出 / 当前用户 / 菜单树
│ │ ├── users.py # 用户 CRUD + 绑定角色/岗位
│ │ ├── roles.py # 角色 CRUD + 绑定菜单
│ │ ├── menus.py # 菜单树 CRUD
│ │ ├── orgs.py # 组织架构树 CRUD
│ │ ├── posts.py # 岗位 CRUD
│ │ └── tenants.py # 租户 CRUD
│ └── services/
│ ├── __init__.py
│ ├── auth_service.py # 认证服务
│ ├── user_service.py # 用户服务
│ ├── role_service.py # 角色服务
│ ├── menu_service.py # 菜单服务
│ ├── org_service.py # 组织架构服务
│ ├── post_service.py # 岗位服务
│ ├── tenant_service.py # 租户服务
│ └── data_scope.py # 数据权限过滤
alembic/versions/auth_module.py # 迁移文件
api-contract-auth.md # 接口契约
docs/auth-module-guide.md # 接入与扩展指南
What ships with it
17 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
- api-contract-auth.md 8.5 KB
- README.md 5.8 KB
- references/dependencies.py 1.2 KB runs code
- references/routers/menus.py 2.1 KB runs code
- references/routers/orgs.py 2.6 KB runs code
- references/routers/posts.py 2.3 KB runs code
- references/routers/roles.py 2.3 KB runs code
- references/routers/tenants.py 2.0 KB runs code
- references/services/__init__.py 552 B runs code
- references/services/auth_service.py 6.9 KB runs code
- references/services/menu_service.py 4.9 KB runs code
- references/services/org_service.py 4.2 KB runs code
- references/services/post_service.py 3.5 KB runs code
- references/services/role_service.py 5.8 KB runs code
- references/services/tenant_service.py 2.9 KB runs code
- references/services/user_service.py 6.6 KB runs code
- references/skeleton.py 24 KB runs code
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 162 lines · 114 tokens per session scan A 324abdb6c353
fastapi-auth-module-skill is a skill published in the GitHub repository jiushiwon/wg-skills (97 stars, last pushed 2d ago), licensed Apache-2.0. It adds 114 tokens to every session and 2,058 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
mem0-oss-to-platform
Plan and then execute a migration of a project from the mem0 open-source / self-hosted SDK (the local Memory class) to the mem0 Platform / hosted / managed SDK (the MemoryClient class). Use this whenever a developer wants to move, switch, or migrate their mem0 usage off OSS/self-hosted to the hosted API — e.g.…
agui-dotnet-protobuf
Use the protobuf wire transport (instead of the default Server-Sent Events) for an AG-UI connection with the AG-UI .NET SDK — a compact binary event stream negotiated via the Accept header. USE FOR: making an AGUIChatClient prefer protobuf by wiring an AGUIEventStreamHandler with ProtobufEventStreamFormatter (then…
azure-mgmt-botservice-dotnet
Azure Resource Manager SDK for Bot Service in .NET. Management plane operations for creating and managing Azure Bot resources, channels (Teams, DirectLine, Slack), and connection settings. Triggers: "Bot Service", "BotResource", "Azure Bot", "DirectLine channel", "Teams channel", "bot management .NET", "create bot".
fastapi-router-py
Create FastAPI routers with CRUD operations, authentication dependencies, and proper response models. Use when building REST API endpoints, creating new routes, implementing CRUD operations, or adding authenticated endpoints in FastAPI applications.
migrate-segw-to-rap
Reverse-engineer a SEGW-built OData V2 service (MPC/DPC/MPCEXT/DPCEXT) into a modern RAP V4 service — tables, CDS views (interface + projection), behavior definitions, draft entities, service definition + binding. Use when asked to "migrate this SEGW service to RAP", "convert OData V2 to V4 RAP", "modernize this…
telnyx-messaging-hosted-curl
Set up hosted SMS numbers, toll-free verification, and RCS messaging. Use when migrating numbers or enabling rich messaging features. This skill provides REST API (curl) examples.