Commit Graph

2 Commits

Author SHA1 Message Date
Geutebruck API Developer
49b9fdfb81 Implement Server CRUD with bool type fix and auto-increment IDs
CRITICAL FIX: Changed boolean fields from int32 to bool type
- Enabled, DeactivateEcho, DeactivateLiveCheck now use proper bool type (type code 1)
- Previous int32 implementation (type code 4) caused servers to be written but not recognized by GeViSet
- Fixed field order to match working reference implementation

Server CRUD Implementation:
- Create, Read, Update, Delete operations via gRPC and REST API
- Auto-increment server ID logic to prevent conflicts
- Proper field ordering: Alias, DeactivateEcho, DeactivateLiveCheck, Enabled, Host, Password, User

Files Added/Modified:
- src/sdk-bridge/GeViScopeBridge/Services/ConfigurationServiceImplementation.cs (bool type fix, CRUD methods)
- src/sdk-bridge/Protos/configuration.proto (protocol definitions)
- src/api/routers/configuration.py (REST endpoints)
- src/api/protos/ (generated protobuf files)
- SERVER_CRUD_IMPLEMENTATION.md (comprehensive documentation)

Verified:
- Servers persist correctly in GeViSoft configuration
- Servers visible in GeViSet with correct boolean values
- Action mappings CRUD functional
- All test scripts working (server_manager.py, cleanup_to_base.py, add_claude_test_data.py)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-16 18:35:36 +01:00
Geutebruck API Developer
cda42ebc6e Add server CRUD with persistence and fix action mappings endpoint
- Implement complete server CRUD operations with GeViServer persistence
  - POST /api/v1/configuration/servers - Create new server
  - PUT /api/v1/configuration/servers/{server_id} - Update server
  - DELETE /api/v1/configuration/servers/{server_id} - Delete server
  - GET /api/v1/configuration/servers - List all servers
  - GET /api/v1/configuration/servers/{server_id} - Get single server

- Add write_configuration_tree method to SDK bridge client
  - Converts tree to JSON and writes via import_configuration
  - Enables read-modify-write pattern for configuration changes

- Fix action mappings endpoint schema mismatch
  - Transform response to match ActionMappingListResponse schema
  - Add total_mappings, mappings_with_parameters fields
  - Include id and offset in mapping responses

- Streamline configuration router
  - Remove heavy endpoints (export, import, modify)
  - Optimize tree navigation with depth limiting
  - Add path-based configuration access

- Update OpenAPI specification with all endpoints

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2025-12-16 09:48:10 +01:00