svn_clear_credentials
Clear SVN credential cache to resolve authentication errors and ensure reliable access to repositories.
Instructions
Limpiar cache de credenciales SVN para resolver errores de autenticación
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- index.ts:542-566 (registration)MCP server.tool registration for 'svn_clear_credentials' tool. Includes inline handler function that calls SvnService.clearCredentials() and formats response."svn_clear_credentials", "Limpiar cache de credenciales SVN para resolver errores de autenticación", {}, async () => { try { const result = await getSvnService().clearCredentials(); const clearText = `🔐 **Cache de Credenciales Limpiado**\n\n` + `**Comando:** ${result.command}\n` + `**Tiempo de Ejecución:** ${formatDuration(result.executionTime || 0)}\n\n` + `**Resultado:**\n\`\`\`\n${result.data}\n\`\`\`\n\n` + `**Nota:** Esto puede ayudar a resolver errores como:\n` + `• E215004: No more credentials or we tried too many times\n` + `• Errores de autenticación por credenciales cacheadas incorrectamente`; return { content: [{ type: "text", text: clearText }], }; } catch (error: any) { return { content: [{ type: "text", text: `❌ **Error:** ${error.message}` }], }; } } );
- tools/svn-service.ts:824-826 (handler)SvnService.clearCredentials() method delegated by MCP handler.async clearCredentials(): Promise<SvnResponse> { return await clearSvnCredentials(this.config); }
- common/utils.ts:423-451 (helper)Core implementation: clearSvnCredentials executes 'svn auth --remove' to clear SVN credentials cache, with fallback.export async function clearSvnCredentials(config: SvnConfig): Promise<SvnResponse> { try { // En sistemas Unix/Linux, SVN guarda credenciales en ~/.subversion/auth // En Windows, en %APPDATA%\Subversion\auth // Intentar limpiar usando el comando auth específico si está disponible // Primero intentar con el comando de limpieza estándar return await executeSvnCommand(config, ['auth', '--remove'], { noAuthCache: true }); } catch (error: any) { // Si el comando auth no está disponible, intentar alternativa try { // Como fallback, usar un comando que no guarde credenciales const response = await executeSvnCommand(config, ['info', '--non-interactive'], { noAuthCache: true }); return { success: true, data: 'Cache de credenciales limpiado (usando método alternativo)', command: 'clear-credentials', workingDirectory: config.workingDirectory! }; } catch (fallbackError: any) { return { success: false, error: `No se pudo limpiar el cache de credenciales: ${fallbackError.message}`, command: 'clear-credentials', workingDirectory: config.workingDirectory! }; } } }