renderDefaultJSONMCPConfig is a convenience wrapper for renderStandardJSONMCPConfig used by simple JSON engines (Claude, Gemini, Crush, OpenCode) that share the standard renderCustomMCPConfigWrapperWithContext callback and differ only in their config path.
( sb *strings.Builder, tools map[string]any, mcpTools []string, workflowData *WorkflowData, configPath string, )
| 93 | // simple JSON engines (Claude, Gemini, Crush, OpenCode) that share the standard |
| 94 | // renderCustomMCPConfigWrapperWithContext callback and differ only in their config path. |
| 95 | func renderDefaultJSONMCPConfig( |
| 96 | sb *strings.Builder, |
| 97 | tools map[string]any, |
| 98 | mcpTools []string, |
| 99 | workflowData *WorkflowData, |
| 100 | configPath string, |
| 101 | ) error { |
| 102 | return renderStandardJSONMCPConfig(sb, renderStandardJSONMCPConfigOptions{ |
| 103 | tools: tools, |
| 104 | mcpTools: mcpTools, |
| 105 | workflowData: workflowData, |
| 106 | configPath: configPath, |
| 107 | renderCustom: func(builder *strings.Builder, toolName string, toolConfig map[string]any, isLast bool) error { |
| 108 | return renderCustomMCPConfigWrapperWithContext(builder, toolName, toolConfig, isLast, workflowData) |
| 109 | }, |
| 110 | }) |
| 111 | } |
| 112 | |
| 113 | // renderStandardJSONMCPConfig is a shared helper for JSON MCP config rendering used by |
| 114 | // Claude, Gemini, Copilot, and Codex engines. It consolidates the repeated sequence of: |
no test coverage detected