feat: HubClient.moduleInfo for Studio module-detail sheet

Wraps the existing HubAdmin.ModuleInfo RPC so Studio can
render a detail panel for one module without re-implementing
the proto types.

Bumps fai_dart_sdk 0.3.0 -> 0.4.0.

Signed-off-by: flemming-it <stefan.a.flemming@googlemail.com>
This commit is contained in:
flemming-it 2026-05-05 22:13:49 +02:00
parent 1eaa36b1a0
commit a2e3f4514a

View file

@ -40,6 +40,7 @@ typedef LoggedEvent = pb.LoggedEvent;
typedef PendingApprovalEntry = pb.PendingApprovalEntry;
typedef DeclaredService = pb.DeclaredService;
typedef VerifyEventChainResponse = pb.VerifyEventChainResponse;
typedef ModuleInfoResponse = pb.ModuleInfoResponse;
/// Typed client for the FI Hub gRPC surface. Construct once,
/// reuse for the process lifetime, call [close] on shutdown.
@ -99,6 +100,13 @@ class HubClient {
return r.capabilities;
}
/// Detailed info for one installed module: name, version,
/// provided capabilities, declared permissions, on-disk path.
Future<ModuleInfoResponse> moduleInfo(String moduleName) {
final req = pb.ModuleInfoRequest()..moduleName = moduleName;
return _admin.moduleInfo(req);
}
/// Recent events from the audit log, newest-first. Pass an
/// empty `types` list for all event types.
Future<List<LoggedEvent>> eventLog({