Installation
grab — get the file, not the whole monorepo
Paste a public GitHub URL (or an npm package). zephex grabs just that file or folder into your project — no git clone, no full zip hunt. Same idea on the web terminal: real Downloads + open in VS Code in the browser.
Reference: All grab commands & flags · Terminal CLI · Web Terminal · Install / npx
# One file into the current projectzephex grab https://github.com/xai-org/grok-build/blob/main/.cargo/config.toml # A whole folder (keeps structure)zephex grab https://github.com/owner/repo/tree/main/docs # npm package (or a path inside it)zephex grab npm:lodashzephex grab npm:chalk@5.3.0 # Preview without writingzephex grab https://github.com/owner/repo/tree/main/src --dry-run # Undo the last grab in this projectzephex grab --undo # Or without a global installnpx zephex grab https://github.com/owner/repo/blob/main/README.mdgrab in one sentence
zephex grab takes a public GitHub file, folder, or npm package and writes it into your current project directory— so you can use someone else's snippet, config, or SDK folder without cloning their entire monorepo.
Single file
One path → one write
Blob URLs (or raw GitHub links) drop the file locally. Nested paths like .cargo/config.toml keep folders automatically.
Folder
Tree under that path
Tree URLs pull every file under that directory — parallel download, structure preserved. Great for docs/, examples/, or a small package folder.
npm
Package into a folder
npm:name, npm:name@version, or npmjs / unpkg links. Useful when you want the tarball contents next to your code, not only node_modules.
Web terminal
Browser Downloads + open code
Same grab command on zephex.dev web terminal: files go to Downloads (folder = zip). Then Open in VS Code opens the public tree in a browser editor (github1s) — no local IDE required.
Pull a config you need right now
cd my-rust-appzephex grab https://github.com/xai-org/grok-build/blob/main/.cargo/config.toml# → writes .cargo/config.toml under my-rust-appSteal an example folder (not the monorepo)
cd playgroundzephex grab https://github.com/openclaw/openclaw/tree/main/examples/ai-chat# → examples/ai-chat/README.md, index.mjs, package.json, …Drop an npm package for inspection
zephex grab npm:ms@2.1.3# → ms-2.1.3/index.js, package.json, readme, … # Optional: put it somewhere elsezephex grab npm:lodash --out ./vendorAlready there? Force or undo
zephex grab <url> --force # overwritezephex grab --undo # remove last grab in this projectzephex grab <url> --dry-run # list files onlyLocal CLI prints a short card: source, path, each file written, size, and Open in VS Code / github.dev links so you can browse the same path in the browser. Web terminal also shows a one-click bar after download.
↓ grab › owner/repo@main path examples/ai-chat dest . mode parallel files ✓ examples/ai-chat/index.mjs 2.7 KB ✓ examples/ai-chat/README.md 1.9 KB Grabbed 2 files · … next grab --undo removes this grab open Open in VS Code https://github1s.com/…Use grab when…
You need one file or a small folder from a public repo · you want an example without cloning · you want to inspect an npm package as plain files · you are on the web terminal and want a real download (or zip) plus browser code view.
Not for…
Private repos (without a token that can read them) · multi‑GB full monorepos as your default move (use git clone / sparse checkout) · installing packages into node_modules (use npm/pnpm for that).
The moves people actually brag about
1
Clone zero, ship the snippet
Need one Cargo.toml, one GitHub Action, or one example agent folder from a 50k‑file monorepo? grab pulls that path only — no multi‑GB clone, no hunting zipballs.
2
Nested paths stay nested
Paste …/blob/main/.cargo/config.toml and you get .cargo/config.toml under your project — not a flat file dumped into cwd. Same for deep SDK trees.
3
github1s / github.com / raw — all fine
Copy from the browser bar whether you are on GitHub, github1s (VS Code web), or raw.githubusercontent.com. grab normalizes the host and still writes the right path.
4
npm as real files
zephex grab npm:ms@2.1.3 expands the package into a folder you can open, diff, and teach from — not only whatever landed in node_modules after install.
5
Undo is first-class
Every grab leaves a tiny project manifest. zephex grab --undo removes exactly what the last grab wrote — no manual file archaeology.
6
Web = Downloads + open in VS Code
Same command in the web terminal: real browser Downloads (folder = zip with full tree). Then Open in VS Code jumps to github1s so you can read the tree without installing an editor.
7
Zero Zephex credits
grab does not spend your plan's MCP request budget. It talks to public GitHub / npm only. Your Zephex API key is for other tools — not required for grab itself.
8
Dry-run before you pollute the tree
--dry-run lists every file and size with no write. --force overwrites when you mean it. Safe defaults when a file is already on disk.
This is GitHub's limit — not a Zephex API key
When grab fails with GitHub rate limit hit, it is almost never about your Zephex mcp_… dashboard key. That key is for hosted MCP tools and billing. grab does not charge Zephex credits and does not require a Zephex key to download public files.
The limit is GitHub's REST API (used for folders, full repos, and some metadata). Without a GitHub personal access token (PAT), GitHub allows about 60 requests per hour per IP. After that, folder grabs fail until the window resets (about an hour) or you authenticate.
Single file
Usually no token needed
Single-file grabs prefer raw.githubusercontent.com, which does not burn the 60/hr API bucket the same way. That is why a lone Cargo.toml often works even after folder grabs start failing.
Folder / full repo
Needs API → token helps a lot
Listing a tree uses the API. With a PAT you jump to roughly 5,000 requests/hour for public repos (no scopes required for public read).
npm
Registry, not GitHub API
npm:… grabs go through the npm registry / tarball. GitHub rate limits do not apply the same way (though network can still fail).
How to fix a rate limit (pick one)
# 1) Classic PAT — public repos need NO scopes# https://github.com/settings/tokensexport GITHUB_TOKEN=ghp_your_token_here# same idea:export GH_TOKEN=ghp_your_token_here # 2) GitHub CLI already logged in — grab can read it automaticallygh auth login# optional explicit:export GITHUB_TOKEN=$(gh auth token) # 3) Put it in your shell profile so every terminal has itecho 'export GITHUB_TOKEN=ghp_…' >> ~/.zshrc && source ~/.zshrc # Then retryzephex grab https://github.com/owner/repo/tree/main/docsExpired token? Switch to another
GitHub PATs can expire or be revoked. grab only uses one token per process, in this order:
GITHUB_TOKENenvGH_TOKENenvZEPHEX_GITHUB_TOKENenv (optional alias)gh auth tokenif the GitHub CLI is installed and logged in
If one token is dead, export a fresh one (or re-run gh auth login). You can keep multiple PATs in a password manager and swap:
# Token A expired or rate-limited on a shared CI user?export GITHUB_TOKEN=ghp_SECOND_TOKENzephex grab https://github.com/owner/repo/tree/main/src # Check GitHub's view of your quota (with token)curl -sH "Authorization: Bearer $GITHUB_TOKEN" https://api.github.com/rate_limit | headThere is no built-in “try token 1 then token 2” list yet — set the env var you want for that shell (or CI job). Rotating PATs is the normal, safe pattern.
Do not put a GitHub PAT in your Zephex dashboard as if it were an MCP API key. Keep GITHUB_TOKEN in the shell / CI secrets. Keep mcp_… keys for Zephex tools that need them.
| Surface | Cap (defaults) |
|---|---|
| Local CLI | ~2000 files · ~80 MB total (raise with --max-mb) |
| Web · single file | ~8 MB |
| Web · folder zip | ~500 files · ~25 MB |
| Web · full repo | GitHub zipball (confirm; can be large) |
grab is free of MCP tool credits — it only talks to public GitHub / npm. You do not spend plan requests just to download a file.
Full command & flag reference · Web Terminal · Terminal tools · Slash commands