Remove legacy client-manager platform path

This commit is contained in:
npc0-hue
2026-09-03 16:40:05 +08:00
parent ec2462a312
commit 80cddbf19d
51 changed files with 382 additions and 4271 deletions
+12
View File
@@ -81,6 +81,18 @@ export function PluginPageHostPage({ params, onNavigate, initialPlugin, embedded
list: (filter) => platformApiClient.listGameClientBridgeCommands(serverId, filter),
snapshots: (query) => platformApiClient.listGameClientBridgeSnapshots(serverId, query)
},
logs: {
listStreams: () => {
const context = hostContextRef.current;
if (!serverId || !context?.permissions.includes("server.logs.read")) throw new Error("plugin page is missing server.logs.read");
return platformApiClient.listLogStreams(serverId);
},
query: (request) => {
const context = hostContextRef.current;
if (!serverId || !context?.permissions.includes("server.logs.read")) throw new Error("plugin page is missing server.logs.read");
return platformApiClient.queryLogStream(request);
}
},
dispatch: (envelope, signal) => {
const context = hostContextRef.current;
if (!context) return Promise.resolve({ requestId: envelope.requestId, action: envelope.action, status: "error", error: { code: "host_unavailable", message: "plugin bridge host is unavailable" } });