@mangomagic/cli
v0.1.18
Published
MangoMagic CLI — sign in, manage episodes, and expose MangoMagic to MCP clients (Claude Desktop, Cursor).
Downloads
3,084
Readme
@mangomagic/cli
The MangoMagic command-line companion.
npx -y @mangomagic/cli loginYou'll get a short code, your browser will open, you approve the device, and
the CLI plays the animated MangoMagic splash to confirm you're in. In a normal
terminal, login then drops straight into chat mode so users can start typing.
The token is cached at ~/.mangomagic/credentials.json (mode 0600) so the next
runs skip auth.
Commands
| Command | What it does |
| --- | --- |
| mangomagic login | Browser-based device-code sign-in, splash, then chat. Add --home to stop at the menu or --no-open to print the URL without opening a browser. |
| mangomagic logout | Forget the cached token. |
| mangomagic whoami | Show the cached identity. |
| mangomagic home | Show fast wins after sign-in. |
| mangomagic chat | Play the splash and start an interactive natural-language session. |
| mangomagic ask "..." | Run one natural-language request. |
| mangomagic tools | Show the CLI/MCP catalog. Add --all for the full list or --json for machine-readable output. |
| mangomagic tool <name> '{"json":"args"}' | Run the same tool exposed to MCP clients. |
| mangomagic cards "idea" | Create talking cards, save cloud drafts, and export local files under ~/MangoMagic/exports/talking-cards. Add --count 3. |
| mangomagic open cards | Open the Talking Cards workspace in a browser. |
| mangomagic splash | Show the splash once. --anim, --loop supported. |
| mangomagic mcp | Run as a stdio MCP server. Wire into Claude Desktop / Cursor. |
| mangomagic mcp-config | Print MCP client JSON for copy-paste. |
Use as an MCP server
Add to Claude Desktop's claude_desktop_config.json (or Cursor's MCP settings):
{
"mcpServers": {
"mangomagic": {
"command": "npx",
"args": ["-y", "@mangomagic/cli", "mcp"]
}
}
}The MCP server uses the same token cached by mangomagic login, so make sure
you sign in first.
MCP exposes:
- Core user tools such as
list_episodes,get_episode, andsearch_episodes. - First-class MangoMagic business tools such as
get_user_stats,get_user_clips,create_clip,qualify_leads, andgenerate_viral_caption. - Admin/raw Edge Function tools prefixed with
edge_, for exampleedge_generate_carousels. These go through a server-side runner with role checks and dry-run protection for webhook/auth/billing callbacks.
Natural language
npx -y @mangomagic/cli chat
npx -y @mangomagic/cli create talking cards about AI adoption
npx -y @mangomagic/cli cards "why founder-led sales stalls" --count 3Obvious requests are handled locally. Fuzzy routing uses MangoMagic's backend AI router, so end users never need to provide a Moonshot/Kimi key.
Talking card creation writes a local bundle by default:
index.htmlfor a browser previewREADME.mdfor the slide copy and edit linkscaptions.txtfor captionscards.jsonfor structured data
Set MANGOMAGIC_EXPORT_DIR to change the export root.
Requirements
Node 18 or later. The splash uses true-color ANSI; on terminals without it, the CLI falls back to a plain banner.
