Commit Graph
19 Commits
Author SHA1 Message Date
Jeppe B 2a6a86c9c3 Resolve backend Qodana critical and high findings (#314)
Resolve recommended-profile Critical and High findings, retain narrow analyzer exceptions, and update the edge-broker WebSocket dependency to a non-vulnerable release.
2026-07-17 05:44:16 +02:00
Jeppe Bundgaard 42f8ae0c47 Refactor input value handling and improve validation in ObjectsGlobal component 2026-06-29 11:08:50 +02:00
Jeppe Bundgaard d52ceb8513 Add robust release update and API health checks
This commit introduces a release update mechanism, including candidate detection, asset pre-downloading, and installation workflows with proper state management. Additionally, it implements API health checks both for successful and failure scenarios and adds related unit and e2e tests for enhanced reliability.
2026-05-27 13:24:15 +02:00
Jeppe Bundgaard 39d745e079 Remove ws module from edge-agent dependencies 2026-04-14 19:33:07 +02:00
Jeppe Bundgaard c23bfb6d2f Update workerRoute version to 1.0.2 2026-04-14 18:58:47 +02:00
Jeppe Bundgaard ac164a5e81 Add debug Redis configuration support, enhance Redis connection handling, and refactor worker status endpoint 2026-03-24 10:09:37 +01:00
Jeppe Bundgaard de89c4d635 Add database and Redis port configuration support, connection health checks, and refactor worker status endpoint. 2026-03-20 13:01:21 +01:00
Jeppe Bundgaard 29c53c3b70 Improve Slack message formatting and update date handling in department statistics
- Apply Markdown formatting to Slack messages for better readability.
- Adjust date range to end on the previous day in `workerRoute.php`.
- Refactor department loop output for consistent indentation and styling.
2026-01-22 12:53:38 +01:00
Jeppe Bundgaard 127be6ece7 Disable /worker/test endpoint and update Slack notification method in workerRoute.php 2026-01-22 08:58:52 +01:00
Jeppe Bundgaard 9b41f80ea5 Add methods to retrieve and analyze product sales data, send department statistics to Slack, and implement scheduled messaging logic 2026-01-21 13:42:19 +01:00
Jeppe Bundgaard 3c46ee86ec Add routes for worker version management
- Introduced `/worker/version` route to retrieve current worker target version.
- Added `/worker/update-version` route to update worker target version with permission and parameter validation.
2025-12-01 15:01:25 +01:00
Jeppe Bundgaard 3e30505cec Add new debug routes for Worker to integrate Shelly API functionality
- Introduced `/worker/debug`, `/worker/debug/on`, and `/worker/debug/off` routes for testing Shelly device states and switch operations.
- Updated routes to handle device state retrieval and switching using the Shelly API with improved error messaging for disabled endpoints.
2025-10-15 13:21:54 +02:00
Jeppe Bundgaard ce9913429f Integrate caching for CVR lookup, add economic customer creation endpoint, and enhance license plate recognition validation
- Implemented Redis caching for CVR lookups to improve performance and reduce API calls.
- Introduced economic customer creation functionality with new `createCustomer` method and corresponding route.
- Enhanced license plate recognition validation to handle plates shorter than 3 characters.
2025-10-13 13:32:11 +02:00
Jeppe Bundgaard ca29ded6be Integrate Virkdata module with new routes, helpers, and configurations
- Added `virkdata` class to handle API operations for company information retrieval and config validation.
- Introduced `virkdata_i` interface and supporting helpers: `virkdata_request_parameters`, `virkdata_response`, and enums for formats, countries, and error codes.
- Implemented new routes: `/worker/debug`, `/worker/licenseplates`, `/cvr/lookup`, and `/economic/doesCustomerExist`.
- Added module `Virkdata` route for searching company data and fetching/updating configurations (`moduleVirkDataRoute`).
- Created `virkdata` module configurations: `enabled`, `secret_key`, and `monthly_limit`.
- Integrated virkdata initialization in `index.php`.
2025-10-12 12:50:57 +02:00
Jeppe Bundgaard 8604cf39de Add /worker/licenseplates route to retrieve unique license plate statistics
- Introduced new endpoint `/worker/licenseplates` to fetch and analyze distinct license plates from multiple database tables.
- Added functionality to format license plates by removing non-alphanumeric characters and converting them to uppercase.
- Integrated response to include counted plates and total unique plates.
- Improved database query logic to handle multiple tables and columns for license plate retrieval.
2025-09-23 09:14:34 +02:00
Jepp9350 c95daeb619 Remove permissions from worker status API response.
The 'permissions' field has been omitted from the worker status API response payload. This ensures a more streamlined response and avoids exposing unnecessary data. The change does not affect the functionality of the API.
2025-02-20 17:13:59 +01:00
Jepp9350 d9638406d3 Implement route-level permission handling.
Added support for defining and registering permissions for API routes. Updated methods across the router and route traits to accommodate permission details, enabling better access control. Enhanced department license plate lookup with session validation and additional endpoints.
2025-02-20 14:12:21 +01:00
Jepp9350 b659b07d4c Add caching support for license plate lookups in MotorAPI
Introduced caching functionality to improve efficiency and reduce redundant API calls for license plate lookups. Added methods to check and retrieve cached entries while ensuring proper validation. Enhanced error handling for invalid responses and updated related routes and interfaces accordingly.
2025-02-20 10:59:09 +01:00
Jepp9350 707df910b0 Refactor: migrate files 2025-01-29 14:27:44 +01:00