# Iconify Skill

> Search Iconify collections and generate SVG icons with size/color customization; use for requests about finding icon IDs, suggesting icons by intent, retrieving SVG markup, or working offline with a bundled icon index.

- Skill: `bingal/iconify-skill` (Agent Skill, multi-file: 6 files)
- Install (CLI): `npx skillmds@latest add bingal/iconify-skill`
- Raw SKILL.md: https://api.skillmd.com/api/skills/bingal/iconify-skill/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: bingal (https://skillmd.com/u/bingal)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/bingal/iconify-skill

---


# Iconify Skill

Use the CLI in `scripts/iconify_cli.py` to search, suggest, and fetch SVG icons.

## Quickstart

1. Ensure Python 3 is available.
2. Run `doctor` to validate the environment.
3. If the offline index is missing, build it.

```bash
python3 $SKILL_DIR/scripts/iconify_cli.py doctor
```

```bash
python3 $SKILL_DIR/scripts/iconify_cli.py build-index
```

## Command Interface

```bash
python3 $SKILL_DIR/scripts/iconify_cli.py <command> [arguments]
```

## Common Commands

- `list-collections` - List icon sets
- `search <query>` - Search icons (offline curated index + online fallback)
- `get <prefix:name>` - Get SVG (requires network)
- `suggest "<intent>"` - Suggest icons for intent
- `attribution` - Show license info
- `doctor` - System health check

## Usage Examples

```bash
# Search icons (offline)
python3 $SKILL_DIR/scripts/iconify_cli.py search "close button" --limit 5

# Get SVG with custom styling
python3 $SKILL_DIR/scripts/iconify_cli.py get mdi:home --size 24 --color "#3B82F6"

# Suggest icons for a feature
python3 $SKILL_DIR/scripts/iconify_cli.py suggest "user profile page"

# Filter by collection
python3 $SKILL_DIR/scripts/iconify_cli.py search "home" --prefixes lucide,heroicons
```

## Offline + Data Notes

- `search` uses the bundled SQLite index for curated sets (~32K icons) and automatically falls back to the Iconify online search API for broader coverage.
- `get` needs network access (Iconify API / GitHub raw JSON).
- Use `doctor` to confirm cache/index availability.
- Use `build-index` to regenerate the search index if needed.

## Bundled Collections (~32K icons)

mdi, ph, tabler, simple-icons, lucide, bi, heroicons, feather, radix-icons

These curated MIT/ISC-licensed sets are bundled for fast offline search. Results from outside this list are fetched via the Iconify online search API.

## Output Format

### Exit Codes
- `0` - Success
- `1` - No icons found / invalid arguments
- `2` - Network error (get command)
- `3` - Database error (offline mode)

### SVG Output
```xml
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24">
  <path fill="#3B82F6" d="..."/>
</svg>
<!-- Icon: mdi:check -->
<!-- License: MIT -->
```

## References

- Read `references/REFERENCE.md` for architecture details, CLI behavior, cache paths, and error handling.
- Read `references/LICENSES_AND_ATTRIBUTION.md` when you need license requirements.

