http://localhost:8000/api
GET /health - Returns API health status
- POST /api/auth/login - Login and get JWT token
- GET /api/auth/me - Get current user info
- POST /api/auth/register - Register new user
- PUT /api/auth/change-password - Change password
- GET /api/folder-roots/ - List all folder roots
- POST /api/folder-roots/ - Create a new folder root (with enable_content_indexing, enable_watch_mode)
- GET /api/folder-roots/{id} - Get a specific folder root
- DELETE /api/folder-roots/{id} - Delete a folder root
- POST /api/folder-roots/{id}/scan - Scan a folder root for scripts
- GET /api/scripts/ - List scripts with pagination and filters
- GET /api/scripts/{id} - Get detailed script information
- GET /api/scripts/{id}/content - Get script file content (NEW)
- GET /api/scripts/{id}/history - Get change history for a script (NEW)
- PUT /api/scripts/{id}/status - Update script status
- POST /api/scripts/{id}/tags/{tag_id} - Add a tag to a script
- DELETE /api/scripts/{id}/tags/{tag_id} - Remove a tag from a script
- GET /api/scripts/duplicates/list - Find duplicate scripts
- POST /api/scripts/bulk/tags - Add tags to multiple scripts (NEW)
- POST /api/scripts/bulk/status - Update status for multiple scripts (NEW)
- POST /api/scripts/export - Export script metadata as JSON (NEW)
- POST /api/scripts/import - Import script metadata (NEW)
- GET /api/scripts/{id}/fields - Get all custom fields for a script (NEW)
- PUT /api/scripts/{id}/fields/{key} - Set a custom field value (NEW)
- DELETE /api/scripts/{id}/fields/{key} - Delete a custom field (NEW)
- GET /api/tags/ - List all tags
- POST /api/tags/ - Create a new tag
- GET /api/tags/{id} - Get a specific tag
- DELETE /api/tags/{id} - Delete a tag
- GET /api/tags/{id}/scripts - Get scripts with a specific tag
- GET /api/notes/script/{script_id} - Get notes for a script
- POST /api/notes/script/{script_id} - Create a note (with is_markdown support)
- PUT /api/notes/{note_id} - Update a note
- DELETE /api/notes/{note_id} - Delete a note
- GET /api/notes/{note_id}/render - Render markdown note to HTML (NEW)
- POST /api/notes/preview - Preview markdown rendering (NEW)
- GET /api/folders/ - List all folders (with optional root_id filter)
- GET /api/folders/{id} - Get a specific folder
- GET /api/folders/tree/{root_id} - Get folder tree hierarchy (NEW)
- PUT /api/folders/{id}/note - Update folder note
- DELETE /api/folders/{id}/note - Delete folder note
- GET /api/saved-searches/ - List all saved searches
- POST /api/saved-searches/ - Create a saved search
- GET /api/saved-searches/{id} - Get a specific saved search
- PUT /api/saved-searches/{id} - Update a saved search
- DELETE /api/saved-searches/{id} - Delete a saved search
- POST /api/search/ - Advanced script search with filters:
- query (name/path)
- languages (array)
- tags (array)
- status (array)
- root_ids (array)
- owner (string) - NEW
- environment (string) - NEW
- classification (string) - NEW
- min_size / max_size (integers) - NEW
- modified_after / modified_before (datetime) - NEW
- GET /api/search/stats - Get statistics
- POST /api/fts/ - Full-text search across script content and notes
- POST /api/fts/rebuild - Rebuild FTS index for all or specific root
- GET /api/fts/status - Get FTS index status and statistics
- POST /api/watch/start/{root_id} - Start watching a folder root
- POST /api/watch/stop/{root_id} - Stop watching a folder root
- GET /api/watch/status - Get watch mode status for all roots
- POST /api/watch/start-all - Start watching all enabled roots
- POST /api/watch/stop-all - Stop all watchers
- GET /api/similarity/{script_id} - Find similar scripts (with threshold)
- GET /api/similarity/groups/all - Find all similarity groups
- POST /api/similarity/matrix - Generate similarity matrix for scripts
- GET /api/similarity/compare/{id1}/{id2} - Compare two specific scripts
- POST /api/attachments/upload - Upload attachment (file + script_id or note_id)
- GET /api/attachments/script/{script_id} - List attachments for a script
- GET /api/attachments/note/{note_id} - List attachments for a note
- GET /api/attachments/{id} - Get attachment metadata
- GET /api/attachments/{id}/download - Download attachment file
- DELETE /api/attachments/{id} - Delete attachment
- GET /api/attachments/stats/all - Get attachment statistics
FastAPI provides interactive API documentation:
- Swagger UI: http://localhost:8000/docs
- ReDoc: http://localhost:8000/redoc
For protected endpoints, include JWT token in header:
Authorization: Bearer <your_jwt_token>
Get token via POST /api/auth/login
- Core Features: 41 endpoints
- Optional Features: 32 endpoints