Claude can now write complete Datasette plugins
October 8, 2025 — AI-Built Datasette Plugin
Today marks an interesting milestone: Claude Sonnet 4.5 can now build a complete Datasette plugin entirely from scratch.
While I’ve seen AI models handle portions of this task before, this was the first time I shipped a new plugin where every line of code and every test was written by Claude — with minimal prompting from me.
---
Project Overview
The plugin is datasette-os-info — a simple debugging tool that:
- Adds a `/-/os` JSON endpoint
- Outputs detailed information about the operating system
- Works across different OSes, detecting Docker base images or OS release names
- Live demo here
I built it while experimenting with changing Datasette’s Docker base image to Python 3.14 (background here).
---
Step-by-Step Build Process
1. Create Plugin Template
Using my datasette-plugin cookiecutter template:
uvx cookiecutter gh:simonw/datasette-plugin
[1/8] plugin_name (): os-info
[2/8] description (): Information about the current OS
[3/8] hyphenated (os-info):
[4/8] underscored (os_info):
[5/8] github_username (): datasette
[6/8] author_name ():
[7/8] include_static_directory ():
[8/8] include_templates_directory ():Result: A `datasette-os-info` directory containing
`pyproject.toml`, `tests/`, and `datasette_os_info/__init__.py`.
---
2. Set up and Test Environment
cd datasette-os-info
uv venv
uv sync --extra test
uv run pytest---
3. Launch Claude Code (YOLO Mode)
claude --dangerously-skip-permissions(Shortcut used: `claude-yolo`)
Inside Claude:
- Test command:
- > Run `uv run pytest`
- Build request:
- > Add `/-/os` page returning pretty-printed JSON with maximum OS detail — detect Docker base image where possible.
---
4. AI Implementation
Claude:
- Implemented plugin using `register_routes()`
- Created basic test
- Fixed small bug (`Response(..., default_repr=)` was invalid)
- Declared work complete
---
5. Package & Deploy
uv pip install build
uv run python -m buildUpload wheel to S3, then:
datasette publish ... --install URL-to-wheel---
Security Considerations
The `/-/os` endpoint may reveal sensitive system details.
Highly Sensitive
- Hostname
- Environment variables:
- `HOME`, `USER`, `PATH`, `VIRTUAL_ENV`
- Python executable paths
Moderately Sensitive
- CPU count & memory info
- Kernel version details
If public:
- Data is unauthenticated by default
- Could help attackers profile your environment
Suggested Mitigation
- Require authentication
- Make fields optional
- Add README warning
- Redact sensitive paths
Example Warning:
> ⚠ **Security Note:**
> The `/-/os` endpoint displays system and environment details.
> On a public server, this may expose sensitive information.
> Review endpoint output before deployment.---
README Tip
You can view endpoint output locally without running a server:
datasette --get /-/os---
Final Adjustments
- Added `uv.lock` to `.gitignore`
- Dropped Python 3.9, added Python 3.14 in workflows & `pyproject.toml`
- Updated GitHub Actions to `setup-python@v6`
---
Publishing the Plugin
- Pushed to GitHub
- Enabled Trusted Publishing
- Released v0.1
- Published to PyPI
Quick test without installing Datasette:
uv run --isolated \
--with datasette-os-info \
datasette --get /-/osReference: `--get` CLI option
---
AI Tools & Multi-Platform Publishing
Platforms like AiToEarn enable:
- Seamless AI-assisted content creation
- Multi-platform publishing (Douyin, Kwai, WeChat, Bilibili, Rednote, Facebook, Instagram, LinkedIn, Threads, YouTube, Pinterest, X/Twitter)
- Analytics & AI model ranking
- Open-source, self-hostable workflows
Perfect for releasing technical content, READMEs, or project announcements across multiple destinations without duplicating effort.
Resources:
Documentation | GitHub | Blog
---
Transcript
Full Claude Code session: Gist
---
A year ago I’d have been amazed this worked.
Today, I’m simply impressed — this kind of coding agent + template workflow is now spectacularly efficient.
---
Would you like me to prepare a security-focused AiToEarn publishing workflow so teams can issue cross-platform technical warnings without manual repetition?