And for adding the Sonarcloud MCP server to opencode, create or open the opencode.json file and have it contain:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"sonarcloud": {
"type": "remote",
"url": "https://api.sonarcloud.io/mcp",
"enabled": true,
"headers": {
"Authorization": "Bearer <api-key-here>",
"SONARQUBE_ORG": "xwiki"
}
}
}
}