map-web-applisted
Install: claude install-skill magnusrodseth/dotfiles
# map-web-app
Turn an unknown web app into a scriptable interface.
The output is **not** a one-off automation run. It is a CLI plus a written DOM contract, so the next session and the next agent start from a mapped system instead of re-deriving it by clicking around.
**The core discipline: explore exhaustively before writing anything.** Map every entity, every CRUD operation, and every field's widget type first. Scripts written mid-exploration encode wrong assumptions, and those assumptions fail silently.
## Phase 0: do not scrape if you do not have to
**Always spend the first five minutes here.** Scraping is the expensive path; take it only after ruling out the cheap ones, in this order:
1. **An official REST/GraphQL API.** Check `/api`, `/settings?developer`, the docs site, and the footer.
2. **Is it paywalled?** A documented API you cannot use is not an option. Verify the account can actually mint a key, do not just confirm the endpoint exists.
3. **A published CLI, SDK, or MCP server.** Search before building.
4. **A bulk export.** Even read-only export beats scraping reads.
5. **The app's own XHR calls.** Intercept the network while clicking. Sometimes an internal JSON API is usable with session cookies, which is far more stable than the DOM.
Only when all five fail do you scrape the DOM.
> Record the outcome of this check in the skill you write. "The API is Pro-only" is the single most useful sentence in the artifact, because it stops the next agent re-investiga