MCPcopy Index your code
hub / github.com/simstudioai/sim / mcpOrchestrationStatus

Function mcpOrchestrationStatus

apps/sim/lib/mcp/utils.ts:91–98  ·  view source on GitHub ↗
(errorCode: string | undefined)

Source from the content-addressed store, hash-verified

89 * Maps MCP orchestration error codes to safe HTTP statuses.
90 */
91export function mcpOrchestrationStatus(errorCode: string | undefined): number {
92 if (errorCode === 'validation') return 400
93 if (errorCode === 'forbidden') return 403
94 if (errorCode === 'not_found') return 404
95 if (errorCode === 'conflict') return 409
96 if (errorCode === 'bad_gateway') return 502
97 return 500
98}
99
100/**
101 * Validate string parameter

Callers 6

route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90
route.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected