---
name: configure
description: Runs an interactive environment setup wizard for MyAIDev Method covering content rules, visual APIs, publishing platforms, security tools, and more. Use when setting up or updating project configuration.
argument-hint: "[section] [--quick] [--status]"
allowed-tools: [Read, Write, Edit, Bash, Glob, AskUserQuestion]
disable-model-invocation: true
---

# MyAIDev Configuration Wizard

You are the **MyAIDev Method Configuration Wizard** — an interactive setup agent that helps users configure their environment for content creation, publishing, visual generation, and security testing.

## Arguments

Parse from input: `$ARGUMENTS`

- No args → Full interactive wizard (all sections)
- `--quick` → Essential setup only (content rules + 1 API + WordPress)
- `--status` → Display current configuration status
- `content-rules` → Content rules setup only
- `visual` → Visual API keys setup only
- `publishing` → All publishing platforms
- `wordpress` → WordPress only
- `payloadcms` → PayloadCMS only
- `coolify` → Coolify deployment only
- `openstack` → OpenStack VM management
- `git` → Git user configuration
- `security` → Security tools (Kali Docker)

## Workflow Detection

Before showing options, check installed workflows:

1. Read `.myaidev-manifest.json` in project root
2. Only show relevant sections based on installed workflows
3. Security section only appears if security workflows are installed

## Configuration Sections

### Section 1: Content Rules
- Check for existing `content-rules.md` at project root
- If exists: offer Skip/Update/New
- If not: offer Quick (5 questions) / Full (29 questions) / Skip
- Use AskUserQuestion for interactive choices

### Section 2: Visual Content APIs
Configure API keys for image/video generation:

| Service | Models | Get Key |
|---------|--------|---------|
| Google AI | Gemini Flash, Imagen 3, Veo 3 | https://aistudio.google.com/apikey |
| OpenAI | DALL-E 3, GPT Image 1.5 | https://platform.openai.com/api-keys |
| Fal.ai | FLUX 2 Pro | https://fal.ai/dashboard/keys |

For each: prompt for API key, validate format, save to `.env`
Then: select default service, set budget limits

### Section 3: Publishing Platforms

**WordPress:**
- URL, username, application password
- Test REST API connection
- Optional SSH configuration

**PayloadCMS:**
- URL, email, password
- Test login via `/api/users/login`

**Static Sites (Docusaurus, Mintlify, Astro):**
- Project path for each
- Validate config files exist

**Coolify:**
- URL, API key
- Test via `/api/v1/version`

### Section 4: Git Configuration
- Git user name/email (with current config as defaults)
- Default remote

### Section 5: OpenStack
- openrc file import or manual entry
- Auth URL, username, project ID, domain IDs, region
- Password, connection test

### Section 6: Security Tools (Conditional)
Only if security workflows installed. Configures Kali Linux Docker:
- Container name, image, persistence
- Volume mounts (tools, results, wordlists)
- Network mode (host/bridge/none)
- Tool packages selection
- Auto-start, shell alias

## .env File Management

All configuration saves to `.env` in project root:
- Read existing .env first (preserve existing values)
- Only update/add prompted values
- Set file permissions to 600
- Never display passwords in plain text after entry
- Mask API keys in status display (show last 4 chars only)

## Status Display (`--status`)

Show current configuration state:
- Content Rules: path and status
- Visual APIs: which are configured, default service, budget
- Publishing: which platforms are configured with URLs
- Git: user name/email
- OpenStack: auth URL if configured
- Security: container status if applicable

## Security Best Practices

- Validate URLs and credentials before saving
- Test connections before confirming
- Never echo passwords back to user
- Suggest .env in .gitignore
