- Created docs/ directory for better organization - Moved 35 markdown files from root to docs/ - Includes all status reports, guides, and testing documentation Co-Authored-By: Warp <agent@warp.dev>
2.0 KiB
2.0 KiB
VTL Endpoints - Quick Fix Guide
Issue: 404 Not Found on VTL Endpoints
The VTL endpoints ARE implemented in the code, but the server needs to be restarted to load them.
✅ Solution: Restart the API Server
Option 1: Quick Restart Script
# Rebuild and get restart instructions
./scripts/restart-api.sh
Option 2: Manual Restart
# 1. Stop the current server
pkill -f calypso-api
# 2. Rebuild
cd backend
go build -o bin/calypso-api ./cmd/calypso-api
# 3. Set environment variables
export CALYPSO_DB_PASSWORD="your_password"
export CALYPSO_JWT_SECRET="your_jwt_secret_min_32_chars"
# 4. Start the server
./bin/calypso-api -config config.yaml.example
Option 3: If Using Systemd
# Rebuild
cd backend
go build -o /opt/calypso/backend/bin/calypso-api ./cmd/calypso-api
# Restart service
sudo systemctl restart calypso-api
# Check status
sudo systemctl status calypso-api
🔍 Verify Routes are Working
After restart, test:
# Should return 401 (unauthorized) NOT 404 (not found)
curl http://localhost:8080/api/v1/tape/vtl/libraries
# With auth, should return 200 with empty array
curl http://localhost:8080/api/v1/tape/vtl/libraries \
-H "Authorization: Bearer $TOKEN"
📋 Implemented Endpoints
All these endpoints are implemented and should work after restart:
✅ GET /api/v1/tape/vtl/libraries
✅ POST /api/v1/tape/vtl/libraries
✅ GET /api/v1/tape/vtl/libraries/:id
✅ DELETE /api/v1/tape/vtl/libraries/:id
✅ GET /api/v1/tape/vtl/libraries/:id/drives
✅ GET /api/v1/tape/vtl/libraries/:id/tapes
✅ POST /api/v1/tape/vtl/libraries/:id/tapes
✅ POST /api/v1/tape/vtl/libraries/:id/load
✅ POST /api/v1/tape/vtl/libraries/:id/unload
🎯 Next Steps After Restart
- Test the endpoints using
./scripts/test-vtl.sh - Create a VTL library via API
- Verify database records are created
- Test load/unload operations
The endpoints are ready - just need the server restarted! 🚀