sunwindy91/spa-api-extract
An agent skill for extracting structured data from JavaScript single-page apps when a normal page fetch fails: when WebFetch times out, returns only bundled JS or comes back as an empty client-rendered shell, it switches to a curl-probe → grep → reconstruct-JSON-API → parse-with-Python pipeline to call the API the page uses internally.
spa-api-extract is an agent skill for extracting structured data from JavaScript single-page apps when a normal page fetch fails. When WebFetch (or any HTML-to-markdown fetcher) times out, returns only obfuscated or bundled JS, or comes back as an empty client-rendered shell, the skill switches to a reliable CLI pipeline: confirm the failure signal, curl-probe headers and the raw HTML skeleton, grep the HTML/JS for fetch() / /api/ endpoints and <script src> tags, reconstruct and request the JSON API (carrying any auth token query param, read-only GET), parse with Python to a UTF-8 file, and verify record count, field completeness and non-empty output. reference.md holds the grep-regex library, common SPA data patterns (REST, GraphQL, __NEXT_DATA, inline window.* JSON), auth variants and a troubleshooting table.
Install
dsh plugin --profile web add github:sunwindy91/spa-api-extractCopied verbatim from the README's DeepSeek Harness (dsh) plugin block (a Chinese note follows: the repo ships its own cordis.patch.yml, so dsh mounts it automatically with no manual patch; the command forwards to pnpm and needs access to github.com).
Compatibility
The repo ships a cordis.patch.yml, so dsh plugin ... add mounts the layer automatically. yaml is a peerDependency (the host already provides it); without it the skill degrades to a built-in minimal frontmatter parser. Installing needs network access to github.com (pnpm inherits git's proxy settings).
Details
- Repo: sunwindy91/spa-api-extract
- Category: Tools & Capabilities
- Stars: 0
- Version: GitHub repo sunwindy91/spa-api-extract (install is a github: spec to the repo itself). The bundle's skill file is kept at the package root so the same tree also loads as a native QwenWork skill without duplicating the file.
Alternatives
1624318455/dsh-plugin-tavily · aaronlei/dsh-web-search-diy · apify/apify-deepseek-harness-plugin