Changed CustomCommandCreatorModel.id from required `int` to `Optional[int] = None`
to allow POST requests to create new creators without specifying an ID (database
auto-generates it).
Bug: Users couldn't create custom commands with /new-cc - API returned 422 error
"Field required" for missing id field.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
Exclude 'creator' nested object from model_dump when creating custom commands.
The issue was that Pydantic was including both creator_id and creator fields,
causing Peewee to receive a nested dict that resulted in NULL creator_id values
in the database insert, violating the NOT NULL constraint.
This fix ensures only creator_id is passed to the ORM for foreign key mapping.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Update CLAUDE.md to reflect PostgreSQL-only architecture
- Add table_name Meta class to CustomCommand models for PostgreSQL
- Remove SQLite-specific LIKE queries, use PostgreSQL ILIKE
- Refactor custom command creator info handling
- Add helper functions for database operations
- Fix creator data serialization in execute endpoint
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Add CustomCommandCreator and CustomCommand models to db_engine.py
- Add comprehensive custom commands API router with full CRUD operations
- Include migration script for transferring 140 commands from sba_is_fun.db
- Add FastAPI integration for /api/v3/custom_commands endpoints
- Implement usage tracking, search, autocomplete, and statistics features
- Add grace period handling for unused commands to prevent deletion
- Include comprehensive documentation for migration process
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>