Imported from bvnks-02/CRM2CP (
AGENTS.md). Install upstream withnpx skills add bvnks-02/CRM2CP. Copyright stays with the author.
OpenCode Instructions
Project Structure & Architecture
simplecrm/: Contains core Django configuration and routing (the Django "project" module).crmapp/: Contains the business logic, API models, views, and serializers for all endpoints.
Developer Workflow & Commands
- Local Server:
python manage.py runserver - Database Migrations:
python manage.py migrate(Uses SQLitedb.sqlite3locally). - Tests:
python manage.py test - Formatting: Uses
autopep8. Apply formatting withautopep8 --in-place --recursive .
Docker Infrastructure
- Development: Run
docker-compose up --build. Thedocker-compose.ymlmounts the local directory as a volume and automatically runs migrations followed by Django'srunserver. - Production: The
Dockerfiledefaults to runninggunicornfor a production-ready server.
API & Framework Details
- Authentication: JWT token-based authentication via
djangorestframework-simplejwt. EnsureAuthorization: Bearer <token>is used when interacting with protected endpoints. - API Documentation: Interactive Swagger UI is auto-generated by
drf-spectacularand is available at/api/docs/when the server is running.