koala73/worldmonitor · error · SafeWebMcpError
scope must be one of: all, signals, map, panels, actions.
Error message
scope must be one of: all, signals, map, panels, actions.
What it means
SafeWebMcpError thrown by search_dashboard when the optional scope argument is present but not one of the allowed dashboard surfaces (all, signals, map, panels, actions). The enum guard protects the downstream search router from unknown scopes.
Source
Thrown at src/services/webmcp.ts:2475
'search_dashboard accepts only query, scope, and limit.',
'validation',
);
}
if (typeof args.query !== 'string') {
throw new SafeWebMcpError('query must be a string.', 'validation');
}
if (args.query.length > MAX_SEARCH_QUERY_CHARS) {
throw new SafeWebMcpError(
`query must be at most ${MAX_SEARCH_QUERY_CHARS} characters.`,
'validation',
);
}
const query = args.query.trim();
if (!query) throw new SafeWebMcpError('query must not be empty.', 'validation');
const scope = args.scope === undefined ? 'all' : args.scope;
if (typeof scope !== 'string' || !DASHBOARD_SEARCH_SCOPES.has(scope as DashboardSearchScope)) {
throw new SafeWebMcpError(
'scope must be one of: all, signals, map, panels, actions.',
'validation',
);
}
const limit = args.limit === undefined ? DEFAULT_SEARCH_RESULTS : args.limit;
if (!Number.isInteger(limit) || Number(limit) < 1 || Number(limit) > MAX_SEARCH_RESULTS) {
throw new SafeWebMcpError(
`limit must be an integer from 1 to ${MAX_SEARCH_RESULTS}.`,
'validation',
);
}
return boundDashboardSearchResult(await app.searchDashboard(
query,
scope as DashboardSearchScope,
Number(limit),
extra,
));View on GitHub (pinned to 9361220cc0)
Solutions
- Use one of the enumerated scopes or omit scope entirely to default to all
- Update the calling client to the current scope list
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at src/services/webmcp.ts:772 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of koala73/worldmonitor@9361220cc0 (2026-08-21).
Data as JSON: /api/errors/9e78354d370e4323.
Report an issue: GitHub.