Setting up basic API Structure

This commit is contained in:
2026-08-28 14:54:54 +02:00
parent 968228cbc3
commit b3a13cd5a2
18 changed files with 974 additions and 0 deletions
@@ -0,0 +1,15 @@
import 'package:ac_web/Api/Dtos/AgentDto.dart';
import 'package:ac_web/Api/Services/ApiServiceBase.dart';
/// Access to the backend `AgentsController` (`/agents`).
class AgentsService extends ApiServiceBase {
const AgentsService(super.client);
@override
String get controllerRoute => 'agents';
/// `GET /agents` - all known agents including their current tasks.
Future<List<AgentDto>> getAgents() {
return client.getList(route(), AgentDto.fromJson);
}
}