Skip to content
Source
Sign inSign up
pingdotgg/t3code

feat(mcp): expose provider account usage limits #36478

Closedbrockklein(GitHub profile, opens in a new tab)wants to merge 1 commit intomain fromrefs/pull/36478/headopened View on GitHub

Showing 13 changed files with 178 additions and 0 deletions (loading 10).

x
0 of 13 viewed, 13 left
17 additions and 0 deletionsapps/server/src/mcp/toolkits/orchestrator/handlers.tsModified
View file
@@ -20,6 +20,23 @@
return yield* service.capabilities(scope, input);
}),
),
+ orchestrator_usage_limits: McpToolAccess.reads((input) =>
+ Effect.gen(function* () {
+ const scope = yield* McpInvocationContext.McpInvocationContext;
+ const target = PeerForwarding.remoteTarget(scope, input.environmentId);
+ if (target !== undefined) {
+ const forwarding = yield* PeerForwarding.PeerForwarding;
+ return yield* forwarding.call(
+ scope,
+ OrchestratorToolkit.tools.orchestrator_usage_limits,
+ target,
+ input,
+ );
+ }
+ const service = yield* OrchestratorMcpService.OrchestratorMcpService;
+ return yield* service.usageLimits(scope);
+ }),
+ ),
delegate_task: McpToolAccess.actsAsCaller((input) =>
Effect.gen(function* () {
const scope = yield* McpInvocationContext.McpInvocationContext;
17 additions and 0 deletionsapps/server/src/mcp/toolkits/orchestrator/tools.tsModified
View file
@@ -1,6 +1,8 @@
import {
OrchestratorMcpCapabilitiesInput,