/ado-import-areas
Import Azure DevOps area paths from a project and map them to SpecWeave projects. Creates 2-level directory structure with area path-based organization.
> /plugin marketplace add anton-abyzov/specweave > /plugin install sw@specweave
How it fires
How this command gets triggered: by you, by Claude, or both.
- Fires itselfClaude auto-loads it when your prompt matches the work.
- You can call itInvoke it directly when you want it.
- Slash command
/ado-import-areas
Context preview
What this command does when you run it.
Import Azure DevOps area paths from a project and map them to SpecWeave projects. Creates 2-level directory structure with area path-based organization.
Command definition
ado-import-areas.mddescription: Import Azure DevOps area paths from a project and map them to SpecWeave projects. Creates 2-level directory structure with area path-based organization.
Import ADO Area Paths Command
You are an Azure DevOps integration expert. Help the user import area paths from an ADO project and map them to SpecWeave projects.
Command Usage
sw-ado:import-areas # Interactive mode (prompts for project)
sw-ado:import-areas --project MyProduct # Specific ADO project
sw-ado:import-areas --dry-run # Preview without creating directories
sw-ado:import-areas --include-children # Include child area paths
Your Task
When the user runs this command:
Step 1: Validate Prerequisites
1. **Check ADO credentials** exist in `.env`:
- `AZURE_DEVOPS_PAT`
- `AZURE_DEVOPS_ORG`
- `AZURE_DEVOPS_PROJECT`
2. **Check config.json** for existing area path mapping:
- If `sync.profiles.*.config.areaPathMapping` exists, warn user
Step 2: Get Project Name
**If `--project` flag provided:**
- Use the provided project name
**If no flag (interactive mode):**
๐ท Azure DevOps Area Path Import
Enter the ADO project name to import area paths from:
> MyProduct
Fetching area paths from project MyProduct...
Step 3: Fetch and Display Area Paths
import { fetchAreaPathsForProject } from '../lib/ado-board-resolver';
const areaPaths = await fetchAreaPathsForProject(
process.env.AZURE_DEVOPS_ORG,
'MyProduct',
process.env.AZURE_DEVOPS_PAT
);**Display area paths:**
Found 6 area paths in project MyProduct:
1. โ MyProduct\Frontend (45 active items)
2. โ MyProduct\Backend (78 active items)
3. โ MyProduct\Mobile (23 active items)
4. โ MyProduct\DevOps (12 active items)
5. โ MyProduct\Archive (0 items) [deselected - archive]
6. โ MyProduct (root) [deselected - root level]
Select area paths to import (Space to toggle, Enter to confirm)
Step 4: Map Area Paths to SpecWeave Projects
For each selected area path, prompt for SpecWeave project ID:
๐ท๏ธ Mapping area paths to SpecWeave projects:
Area path "MyProduct\Frontend" โ SpecWeave project ID: [fe]
โ Include child area paths? [Y/n]: y
โ Keywords for auto-classification (optional): frontend, ui, angular, css
Area path "MyProduct\Backend" โ SpecWeave project ID: [be]
โ Include child area paths? [Y/n]: y
โ Keywords for auto-classification (optional): api, server, database, c#
Area path "MyProduct\Mobile" โ SpecWeave project ID: [mobile]
โ Include child area paths? [Y/n]: y
โ Keywords for auto-classification (optional): ios, android, xamarin
Area path "MyProduct\DevOps" โ SpecWeave project ID: [devops]
โ Include child area paths? [Y/n]: y
โ Keywords for auto-classification (optional): infrastructure, ci, cd, terraform
**Project ID validation:**
- Must be lowercase, alphanumeric with hyphens
- Must not collide with existing project IDs
- If collision detected, suggest prefixed version: `myproduct-fe` instead of `fe`
Step 5: Create Directory Structure
Create 2-level directory structure:
.specweave/docs/internal/specs/
โโโ ADO-myproduct/ โ Level 1: ADO project
โโโ fe/ โ Level 2: SpecWeave project
โ โโโ .gitkeep
โโโ be/
โ โโโ .gitkeep
โโโ mobile/
โ โโโ .gitkeep
โโโ devops/
โโโ .gitkeepStep 6: Update config.json
Add area path mapping to config:
{
"sync": {
"profiles": {
"ado-default": {
"provider": "ado",
"config": {
"organization": "myorg",
"areaPathMapping": {
"project": "MyProduct",
"mappings": [
{
"areaPath": "MyProduct\\Frontend",
"specweaveProject": "fe",
"includeChildren": true,
"keywords": ["frontend", "ui", "angular", "css"]
},
{
"areaPath": "MyProduct\\Backend",
"specweaveProject": "be",
"includeChildren": true,
"keywords": ["api", "server", "database", "c#"]
},
{
"areaPath": "MyProduct\\Mobile",
"specweaveProject": "mobile",
"includeChildren": true,
"keywords": ["ios", "android", "xamarin"]
},
{
"areaPath": "MyProduct\\DevOps",
"specweaveProject": "devops",
"includeChildren": true,
"keywords": ["infrastructure", "ci", "cd", "terraform"]
}
]
}
}
}
}
},
"multiProject": {
"enabled": true,
"activeProject": "fe",
"projects": {
"fe": {
"name": "Frontend",
"externalTools": {
"ado": {
"areaPath": "MyProduct\\Frontend",
"project": "MyProduct"
}
}
},
"be": {
"name": "Backend",
"externalTools": {
"ado": {
"areaPath": "MyProduct\\Backend",
"project": "MyProduct"
}
}
},
"mobile": {
"name": "Mobile",
"externalTools": {
"ado": {
"areaPath": "MyProduct\\Mobile",
"project": "MyProduct"
}
}
},
"devops": {
"name": "DevOps",
"externalTools": {
"ado": {
"areaPath": "MyProduct\\DevOps",
"project": "MyProduct"
}
}
}
}
}
}Step 7: Display Summary
โ
Azure DevOps Area Paths Import Complete!
๐ท ADO Project: MyProduct
๐ Created: .specweave/docs/internal/specs/ADO-myproduct/
Area paths imported:
โ MyProduct\Frontend โ fe (includes children)
Keywords: frontend, ui, angular, css
โ MyProduct\Backend โ be (includes children)
Keywords: api, server, database, c#
โ MyProduct\Mobile โ mobilRead more
description: Import Azure DevOps area paths from a project and map them to SpecWeave projects. Creates 2-level directory structure with area path-based organization.
Import ADO Area Paths Command
You are an Azure DevOps integration expert. Help the user import area paths from an ADO project and map them to SpecWeave projects.
Command Usage
sw-ado:import-areas # Interactive mode (prompts for project) sw-ado:import-areas --project MyProduct # Specific ADO project sw-ado:import-areas --dry-run # Preview without creating directories sw-ado:import-areas --include-children # Include child area paths
Your Task
When the user runs this command:
Step 1: Validate Prerequisites
1. **Check ADO credentials** exist in `.env`:
- `AZURE_DEVOPS_PAT`
- `AZURE_DEVOPS_ORG`
- `AZURE_DEVOPS_PROJECT`
2. **Check config.json** for existing area path mapping:
- If `sync.profiles.*.config.areaPathMapping` exists, warn user
Step 2: Get Project Name
**If `--project` flag provided:**
- Use the provided project name
**If no flag (interactive mode):**
๐ท Azure DevOps Area Path Import Enter the ADO project name to import area paths from: > MyProduct Fetching area paths from project MyProduct...
Step 3: Fetch and Display Area Paths
import { fetchAreaPathsForProject } from '../lib/ado-board-resolver';
const areaPaths = await fetchAreaPathsForProject(
process.env.AZURE_DEVOPS_ORG,
'MyProduct',
process.env.AZURE_DEVOPS_PAT
);**Display area paths:**
Found 6 area paths in project MyProduct: 1. โ MyProduct\Frontend (45 active items) 2. โ MyProduct\Backend (78 active items) 3. โ MyProduct\Mobile (23 active items) 4. โ MyProduct\DevOps (12 active items) 5. โ MyProduct\Archive (0 items) [deselected - archive] 6. โ MyProduct (root) [deselected - root level] Select area paths to import (Space to toggle, Enter to confirm)
Step 4: Map Area Paths to SpecWeave Projects
For each selected area path, prompt for SpecWeave project ID:
๐ท๏ธ Mapping area paths to SpecWeave projects: Area path "MyProduct\Frontend" โ SpecWeave project ID: [fe] โ Include child area paths? [Y/n]: y โ Keywords for auto-classification (optional): frontend, ui, angular, css Area path "MyProduct\Backend" โ SpecWeave project ID: [be] โ Include child area paths? [Y/n]: y โ Keywords for auto-classification (optional): api, server, database, c# Area path "MyProduct\Mobile" โ SpecWeave project ID: [mobile] โ Include child area paths? [Y/n]: y โ Keywords for auto-classification (optional): ios, android, xamarin Area path "MyProduct\DevOps" โ SpecWeave project ID: [devops] โ Include child area paths? [Y/n]: y โ Keywords for auto-classification (optional): infrastructure, ci, cd, terraform
**Project ID validation:**
- Must be lowercase, alphanumeric with hyphens
- Must not collide with existing project IDs
- If collision detected, suggest prefixed version: `myproduct-fe` instead of `fe`
Step 5: Create Directory Structure
Create 2-level directory structure:
.specweave/docs/internal/specs/
โโโ ADO-myproduct/ โ Level 1: ADO project
โโโ fe/ โ Level 2: SpecWeave project
โ โโโ .gitkeep
โโโ be/
โ โโโ .gitkeep
โโโ mobile/
โ โโโ .gitkeep
โโโ devops/
โโโ .gitkeepStep 6: Update config.json
Add area path mapping to config:
{
"sync": {
"profiles": {
"ado-default": {
"provider": "ado",
"config": {
"organization": "myorg",
"areaPathMapping": {
"project": "MyProduct",
"mappings": [
{
"areaPath": "MyProduct\\Frontend",
"specweaveProject": "fe",
"includeChildren": true,
"keywords": ["frontend", "ui", "angular", "css"]
},
{
"areaPath": "MyProduct\\Backend",
"specweaveProject": "be",
"includeChildren": true,
"keywords": ["api", "server", "database", "c#"]
},
{
"areaPath": "MyProduct\\Mobile",
"specweaveProject": "mobile",
"includeChildren": true,
"keywords": ["ios", "android", "xamarin"]
},
{
"areaPath": "MyProduct\\DevOps",
"specweaveProject": "devops",
"includeChildren": true,
"keywords": ["infrastructure", "ci", "cd", "terraform"]
}
]
}
}
}
}
},
"multiProject": {
"enabled": true,
"activeProject": "fe",
"projects": {
"fe": {
"name": "Frontend",
"externalTools": {
"ado": {
"areaPath": "MyProduct\\Frontend",
"project": "MyProduct"
}
}
},
"be": {
"name": "Backend",
"externalTools": {
"ado": {
"areaPath": "MyProduct\\Backend",
"project": "MyProduct"
}
}
},
"mobile": {
"name": "Mobile",
"externalTools": {
"ado": {
"areaPath": "MyProduct\\Mobile",
"project": "MyProduct"
}
}
},
"devops": {
"name": "DevOps",
"externalTools": {
"ado": {
"areaPath": "MyProduct\\DevOps",
"project": "MyProduct"
}
}
}
}
}
}Step 7: Display Summary
โ
Azure DevOps Area Paths Import Complete!
๐ท ADO Project: MyProduct
๐ Created: .specweave/docs/internal/specs/ADO-myproduct/
Area paths imported:
โ MyProduct\Frontend โ fe (includes children)
Keywords: frontend, ui, angular, css
โ MyProduct\Backend โ be (includes children)
Keywords: api, server, database, c#
โ MyProduct\Mobile โ mobilSpec-first AI development: describe a feature โ AI creates spec + plan + tasks, builds autonomously, syncs to GitHub/JIRA. Domain-expert skills for PM, Architect, Frontend, QA learn your patterns permanently. Claude Code, Codex, Cursor, Copilot & more.
Repo: anton-abyzov/specweave
Other commands on specweave.
- /abandon
Abandon an incomplete increment (requirements changed, obsolete)
Open command - /ado-cleanup-duplicates
Clean up duplicate Azure DevOps work items for a Feature. Finds work items with duplicate titles and closes all except the first created item.
Open command - /ado-clone
Clone Azure DevOps repositories to local workspace. Use after init if cloning was skipped, or to add repos later.
Open command - /ado-close
Close Azure DevOps work item when increment complete
Open command - /ado-create
Create Azure DevOps work item from SpecWeave increment
Open command - /ado-import-projects
Import additional Azure DevOps projects post-init with area path mapping, filtering, and dry-run preview
Open command

