codemap_template_remove
Delete a code template permanently
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
name | string | ✅ Required | Template name to delete |
Usage Examples
MCP Usage (for AI Agents like Claude)
json
{
"name": "codemap_template_remove",
"arguments": {
"name": "old-template"
}
}Example Output
JSON Response
json
{
"success": true,
"message": "Template 'old-template' deleted successfully",
"name": "old-template"
}When to Use This Tool
-
Use
- Delete outdated or deprecated templates
- Clean up unused scaffolding patterns
- Remove templates after major project restructuring
- Eliminate duplicate or redundant templates
codemap_template_remove when you need to:
Common Patterns
Cleanup Pattern
1. Audit templates with template_list
2. Identify unused templates
3. Remove outdated ones
4. Document changes in project notesPro Tips
- Permanent deletion: Templates are deleted immediately - no undo available
- Check usage first: Search codebase for template deployments before deleting
- Backup option: Use
codemap_copyon template file before removing if unsure
Best Practices
- Review template usage in routines before deleting
- Document why template was removed in commit message
- Consider renaming instead of deleting if template might be useful later
- Clean up unused templates periodically to keep library focused
Common Mistakes
❌ Mistake: Deleting templates still used in active routines
✅ Instead: Search for template references in routines before removing
❌ Mistake: No backup before deletion
✅ Instead: Copy template file manually if you might need it later
❌ Mistake: Deleting without team communication
✅ Instead: Notify team before removing shared templates
✅ Instead: Search for template references in routines before removing
❌ Mistake: No backup before deletion
✅ Instead: Copy template file manually if you might need it later
❌ Mistake: Deleting without team communication
✅ Instead: Notify team before removing shared templates