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 G1Joshi/Agent-Skills --skill fastapigit clone --depth 1 https://github.com/G1Joshi/Agent-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/g1joshi/agent-skills/fastapi)<a href="https://agentmods.dev/skills/g1joshi/agent-skills/fastapi"><img src="https://agentmods.dev/badge/skills/g1joshi/agent-skills/fastapi/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/g1joshi/agent-skills/fastapi"><img src="https://agentmods.dev/badge/skills/g1joshi/agent-skills/fastapi.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.00036 | $0.01240 |
| Opus 5.5 | $0.00014 | $0.00496 |
| Sonnet 5.5 | $0.00007 | $0.00248 |
| Haiku 4.5 | $0.00004 | $0.00124 |
Grade A, and why
fastapi 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 23d 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 — 164 lines — stays where its author put it; the contents beside it link to each section on GitHub.
FastAPI
FastAPI is a modern, fast (high-performance), web framework for building APIs with Python 3.8+ based on standard Python type hints. It is one of the fastest Python frameworks available.
When to Use
- High-Performance Python Web APIs: Developing modern async APIs built on Starlette and Pydantic.
- AI & Machine Learning Model Serving: Serving PyTorch, TensorFlow, Scikit-learn, and Hugging Face inference endpoints.
- Automatic OpenAPI & Swagger Documentation: Generating interactive documentation with zero manual configuration.
- Data Validation & Type-Safe Payloads: Validating query parameters, paths, headers, and request bodies with Pydantic v2.
Quick Start
from fastapi import FastAPI
from pydantic import BaseModel
app = FastAPI()
class Item(BaseModel):
name: str
price: float
@app.post("/items/")
async def create_item(item: Item):
return {"name": item.name, "price": item.price}
Core Concepts
Async Route Handlers & Pydantic v2 Models
Strict payload parsing and serialization:
from fastapi import FastAPI, HTTPException, status, Depends
from pydantic import BaseModel, EmailStr, Field
from typing import List
app = FastAPI(title="Catalog API", version="2.0.0")
class ProductCreate(BaseModel):
name: str = Field(min_length=2, max_length=100)
price: float = Field(gt=0, description="Price in USD")
tags: List[str] = []
class ProductResponse(ProductCreate):
id: int
is_active: bool = True
@app.post("/products", response_model=ProductResponse, status_code=status.HTTP_201_CREATED)
async def create_product(product: ProductCreate):
# Process and persist product
return {
"id": 101,
"name": product.name,
"price": product.price,
"tags": product.tags,
"is_active": True
}
Dependency Injection System with Depends
Reusing database sessions, authentication, and service clients:
from fastapi import Header, HTTPException
async def verify_api_key(x_api_key: str = Header(...)):
if x_api_key != "secret-internal-key":
raise HTTPException(
status_code=status.HTTP_403_FORBIDDEN,
detail="Invalid API Key"
)
return x_api_key
@app.get("/secure-metrics")
async def get_metrics(api_key: str = Depends(verify_api_key)):
return {"status": "authorized", "system_load": 0.42}
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.
- 23d ago Changed · +5 lines 7c84ec3fb9e2
- 27d ago Changed · +96 lines · +14 tokens per session 827545f1f375
- 1mo ago First seen · 63 lines · 22 tokens per session scan A c5b2604a8a71
fastapi is a skill published in the GitHub repository G1Joshi/Agent-Skills (15 stars, last pushed 23d ago), licensed MIT. It adds 36 tokens to every session and 1,240 once invoked, about $0.0001 per session on Opus 5.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-09-03.
Other skills, from other repositories
python-programming-expert
Expert-level skill for Python programming (Python 3.13/3.14+). Covers type safety, generic syntax (PEP 695), async/await TaskGroups, FastAPI 0.115+, Pydantic v2, uv package manager, Ruff, and pytest in English and Indonesian.
fastapi-async-microservices
Design and develop production-grade asynchronous microservices using FastAPI, Python 3.12+, Pydantic v2 Settings and Schemas, SQLAlchemy 2.0 async sessions, dependency injection, lifespan state management, structured JSON logging, and connection pooling. Trigger when building async Python APIs, microservices, or…
azure-mgmt-apicenter-py
Azure API Center Management SDK for Python. Use for managing API inventory, metadata, and governance across your organization.
python-fastapi-development
Python FastAPI backend development with async patterns, SQLAlchemy, Pydantic, authentication, and production API patterns.
dbos-python
Guide for building reliable, fault-tolerant Python applications with DBOS durable workflows. Use when adding DBOS to existing Python code, creating workflows and steps, or using queues for concurrency control.
fastapi-router-py
Create FastAPI routers following established patterns with proper authentication, response models, and HTTP status codes.