{"id":46093073,"url":"https://github.com/geekjourneyx/jina-cli","last_synced_at":"2026-03-06T23:01:30.444Z","repository":{"id":341164987,"uuid":"1169145602","full_name":"geekjourneyx/jina-cli","owner":"geekjourneyx","description":"A lightweight CLI tool wrapping Jina AI Reader API for AI Agents. Fetch and parse any URL into LLM-friendly   formats (Markdown/Text/HTML). Perfect for reading X(Twitter), blogs, and news sites.","archived":false,"fork":false,"pushed_at":"2026-03-01T16:54:51.000Z","size":83,"stargazers_count":212,"open_issues_count":1,"forks_count":22,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-03-05T23:42:09.088Z","etag":null,"topics":["ai-agent","ai-tools","claude-code","cli","jina-ai-reader","openclaw","skills","url-to-markdown"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/geekjourneyx.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-02-28T08:39:26.000Z","updated_at":"2026-03-05T16:30:57.000Z","dependencies_parsed_at":"2026-03-03T20:00:49.664Z","dependency_job_id":null,"html_url":"https://github.com/geekjourneyx/jina-cli","commit_stats":null,"previous_names":["geekjourneyx/jina-cli"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/geekjourneyx/jina-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekjourneyx%2Fjina-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekjourneyx%2Fjina-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekjourneyx%2Fjina-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekjourneyx%2Fjina-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/geekjourneyx","download_url":"https://codeload.github.com/geekjourneyx/jina-cli/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/geekjourneyx%2Fjina-cli/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30202502,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-06T19:07:06.838Z","status":"ssl_error","status_checked_at":"2026-03-06T18:57:34.882Z","response_time":250,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai-agent","ai-tools","claude-code","cli","jina-ai-reader","openclaw","skills","url-to-markdown"],"created_at":"2026-03-01T18:06:56.908Z","updated_at":"2026-03-06T23:01:30.366Z","avatar_url":"https://github.com/geekjourneyx.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n# jina\n\n### 为 AI Agent 打造的网页阅读 CLI 工具\n\n[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)\n[![GitHub Release](https://img.shields.io/github/v/release/geekjourneyx/jina-cli)](https://github.com/geekjourneyx/jina-cli/releases)\n[![Go Version](https://img.shields.io/badge/Go-1.24+-00ADD8?logo=go)](https://golang.org/)\n[![CLI](https://img.shields.io/badge/CLI-Cobra-29BEB0?logo=terminal)](https://github.com/spf13/cobra)\n\n[English](#english) | [中文](#中文)\n\n\u003c/div\u003e\n\n---\n\n## 中文\n\n### 简介\n\n`jina` 是一个轻量级的命令行工具，封装了 [Jina AI Reader API](https://github.com/jina-ai/reader)，可以将任意 URL 转换为 LLM 友好的输入格式。特别适合阅读 X (Twitter)、博客、新闻网站等复杂网页。\n\n**核心功能：**\n\n- **read** - 读取 URL 内容，输出 Markdown/Text/HTML 格式\n- **search** - 网络搜索，自动获取并处理搜索结果\n\n---\n\n## 安装指南\n\njina 有三种独立的安装方式，根据你的使用场景选择：\n\n### 方式一：OpenClaw Skill（推荐本地 AI 助理）\n\n**什么是 OpenClaw？**\n\nOpenClaw 是一个**本地 AI 助理**（可以理解为\"有终端权限的 Claude\"），运行在你的机器上。它通过 **Skills** 插件扩展能力，支持 9000+ 个技能插件。\n\n**适用场景**：本地 AI 助理、自动化工作流、文件系统操作\n\n**安装方式** - 直接复制 skill 文件：\n\n```bash\n# 创建 jina-cli skill 目录并下载\nmkdir -p ~/.openclaw/workspace/skills/jina-cli\ncurl -o ~/.openclaw/workspace/skills/jina-cli/SKILL.md \\\n  https://raw.githubusercontent.com/geekjourneyx/jina-cli/main/skills/jina-cli/SKILL.md\n```\n\n**验证安装**：\n\n```bash\n# 启动 OpenClaw\nopenclaw\n\n# 在 OpenClaw 中直接使用 jina 命令\n# skill 会自动从 ~/.openclaw/workspace/skills/jina-cli/ 加载\n```\n\n**你将获得**：\n- ✅ 本地 AI 助理直接调用 `jina read` 和 `jina search`\n- ✅ 无需安装 CLI 二进制\n- ✅ 可以处理本地文件、执行脚本等\n\n---\n\n### 方式二：Claude Code Skill（推荐用于 AI 辅助开发）\n\n**适用场景**：在 Claude Code 中使用 AI 协助你处理网页内容\n\n**安装步骤**：\n\n```bash\n# 1. 确保已安装 Node.js 和 Claude Code\nnode --version\n# v18.0.0 或更高版本\n\n# 2. 安装 jina skill\nnpx skills add https://github.com/geekjourneyx/jina-cli --skill jina-cli\n```\n\n**安装后验证**：\n\n```bash\n# 在 Claude Code 中可以直接使用\n# 无需额外操作，skill 会自动加载\n```\n\n**你将获得**：\n- ✅ 在 Claude Code 中直接调用 `jina read` 和 `jina search` 命令\n- ✅ AI 会自动理解 jina 的功能和使用方式\n- ✅ 无需手动安装 CLI 二进制文件\n\n---\n\n### 方式三：CLI 二进制文件（推荐用于终端使用）\n\n**适用场景**：在终端/脚本中使用，或与其他工具集成\n\n#### 一键安装（Linux/macOS）\n\n```bash\ncurl -fsSL https://raw.githubusercontent.com/geekjourneyx/jina-cli/main/scripts/install.sh | bash\n```\n\n安装脚本会自动：\n1. 检测你的系统架构（Linux/macOS，amd64/arm64）\n2. 下载对应平台的二进制文件\n3. 安装到 `~/.local/bin/jina` 或 `~/bin/jina`\n4. 提示如何添加到 PATH（如需要）\n\n#### 验证安装\n\n```bash\n# 检查是否安装成功\njina --version\n# 预期输出: jina version 1.0.0 (构建时间: ..., 提交: ...)\n\n# 测试基本功能\njina read --url \"https://example.com\"\n```\n\n#### 手动安装\n\n如果自动安装失败，可以手动下载：\n\n```bash\n# 1. 下载对应平台的二进制\n# Linux amd64:\nwget https://github.com/geekjourneyx/jina-cli/releases/latest/download/jina-linux-amd64 -O jina\nchmod +x jina\nsudo mv jina /usr/local/bin/\n\n# macOS ARM64 (Apple Silicon):\nwget https://github.com/geekjourneyx/jina-cli/releases/latest/download/jina-darwin-arm64 -O jina\nchmod +x jina\nsudo mv jina /usr/local/bin/\n\n# 2. 验证安装\njina --version\n```\n\n#### 从源码构建\n\n```bash\ngit clone https://github.com/geekjourneyx/jina-cli.git\ncd jina-cli\ngo build -o jina ./cli\nsudo mv jina /usr/local/bin/\n```\n\n---\n\n### 三种安装方式对比\n\n| 特性 | OpenClaw Skill | Claude Code Skill | CLI 二进制 |\n|------|----------------|-------------------|------------|\n| **安装位置** | `~/.openclaw/workspace/skills/jina-cli/` | `~/.claude/skills/` | `~/.local/bin/jina` |\n| **使用环境** | OpenClaw 本地 AI 助理 | Claude Code | 任何终端/脚本 |\n| **AI 集成** | AI 自动理解功能 | AI 自动理解功能 | 需要手动调用 |\n| **文件权限** | ✅ 可访问本地文件系统 | ❌ 受限 | ✅ 完整权限 |\n| **脚本执行** | ✅ 可执行脚本 | ❌ 受限 | ✅ 完整权限 |\n| **更新方式** | 重新下载/`npx skills update` | `npx skills update` | 重新运行安装脚本 |\n| **适用场景** | 本地 AI 助理、自动化 | AI 辅助开发 | 脚本集成、日常使用 |\n\n**推荐选择**：\n- **OpenClaw** → 最强能力，本地运行，可操作文件系统\n- **Claude Code** → 开发体验好，AI 辅助编码\n- **CLI 二进制** → 最轻量，适合脚本集成\n\n**注意**：三种方式完全独立，可以同时安装，互不干扰。\n\n---\n\n### 快速开始\n\n#### 读取网页内容\n\n```bash\n# 读取单个 URL\njina read --url \"https://example.com\"\n\n# 读取 X (Twitter) 帖子\njina read -u \"https://x.com/user/status/123456789\" --with-alt\n\n# 输出 Markdown 格式\njina read -u \"https://example.com\" --output markdown\n\n# 保存到文件\njina read -u \"https://example.com\" --output-file result.md\n```\n\n#### 批量处理\n\n```bash\n# 从文件读取 URL 列表\ncat \u003e urls.txt \u003c\u003c EOF\nhttps://example.com/page1\nhttps://example.com/page2\nhttps://x.com/user/status/123\nEOF\n\njina read --file urls.txt\n```\n\n#### 网络搜索\n\n```bash\n# 搜索关键词\njina search --query \"golang latest news\"\n\n# 限定搜索站点\njina search -q \"AI developments\" --site techcrunch.com --site theverge.com\n\n# 限制结果数量\njina search -q \"climate change\" --limit 10\n```\n\n### 配置管理\n\n配置文件位于 `~/.jina-reader/config.yaml`：\n\n```bash\n# 查看所有配置\njina config list\n\n# 设置配置项\njina config set timeout 60\njina config set with-generated-alt true\n\n# 获取单个配置\njina config get timeout\n\n# 查看配置文件路径\njina config path\n```\n\n### 配置项说明\n\n| 配置项 | 环境变量 | 默认值 | 说明 |\n|--------|----------|--------|------|\n| `api_base_url` | `JINA_API_BASE_URL` | `https://r.jina.ai/` | Read API 地址 |\n| `search_api_url` | `JINA_SEARCH_API_URL` | `https://s.jina.ai/` | Search API 地址 |\n| `default_response_format` | `JINA_RESPONSE_FORMAT` | `markdown` | 响应格式 |\n| `default_output_format` | `JINA_OUTPUT_FORMAT` | `json` | 输出格式 |\n| `timeout` | `JINA_TIMEOUT` | `30` | 请求超时（秒） |\n| `with_generated_alt` | `JINA_WITH_GENERATED_ALT` | `false` | 启用图片描述 |\n| `proxy_url` | `JINA_PROXY_URL` | `\"\"` | 代理服务器 |\n| `api_key` | `JINA_API_KEY` | `\"\"` | API 密钥（用于更高速率限制） |\n\n**优先级：** 命令行参数 \u003e 环境变量 \u003e 配置文件 \u003e 默认值\n\n### API Key 使用\n\n添加 API Key 可以获得更高的速率限制：\n\n```bash\n# 方式 1：配置文件设置\njina config set api_key jina_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n\n# 方式 2：环境变量\nexport JINA_API_KEY=jina_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n\n# 方式 3：命令行参数\njina read -u \"https://example.com\" -k jina_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n```\n\n获取 API Key：访问 [Jina AI Reader](https://jina.ai/reader/#apiform) 注册并获取。\n\n### 输出格式\n\n#### JSON 格式（默认）\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"url\": \"https://example.com\",\n    \"title\": \"Example Domain\",\n    \"content\": \"# Example Domain\\n\\nThis domain is...\"\n  }\n}\n```\n\n#### Markdown 格式\n\n```bash\njina read -u \"https://example.com\" --output markdown\n```\n\n输出：\n```markdown\n# Example Domain\n\n**Source**: https://example.com\n\n---\n\n# Example Domain\n\nThis domain is for use in illustrative examples...\n```\n\n### 高级用法\n\n#### 禁用缓存\n\n```bash\njina read -u \"https://example.com\" --no-cache\n```\n\n#### 使用代理\n\n```bash\njina read -u \"https://example.com\" --proxy \"http://proxy.com:8080\"\n```\n\n#### CSS 选择器提取\n\n```bash\n# 只提取指定元素\njina read -u \"https://example.com\" --target-selector \"article.main\"\n\n# 等待元素加载\njina read -u \"https://example.com\" --wait-for-selector \"#content\"\n```\n\n#### 处理 SPA 应用\n\n```bash\n# 对于带 hash 路由的 SPA，使用 POST 方法\njina read -u \"https://example.com/#/route\" --post\n```\n\n#### 设置 Cookie\n\n```bash\njina read -u \"https://example.com\" --cookie \"session=abc123\"\n```\n\n### 与 AI Agent 集成\n\n```bash\n# 在 Claude Code 或其他 AI 工具中使用\njina read -u \"https://x.com/elonmusk/status/123456\" --output json\n\n# 搜索最新信息\njina search -q \"golang 1.24 release notes\" --output json\n```\n\n### 命令参考\n\n```\njina - CLI tool for Jina AI Reader and Search APIs\n\nUsage:\n  jina [command]\n\nAvailable Commands:\n  read        Extract and convert content from URLs\n  search      Search the web with AI-powered results\n  config      Manage configuration\n  completion  Generate shell completion\n  help        Help about any command\n\nFlags:\n  -a, --api-base string   API base URL (overrides config)\n  -k, --api-key string    API key (overrides config)\n  -o, --output string     Output format: json, markdown (default \"json\")\n  -v, --verbose           Verbose output\n  -h, --help              help for jina\n      --version           version for jina\n```\n\n### 开发\n\n```bash\n# 运行测试\ngo test ./...\n\n# 运行测试并计算覆盖率\ngo test -cover ./...\n\n# 构建\ngo build -o jina ./cli\n\n# 交叉编译\nGOOS=linux GOARCH=amd64 go build -o jina-linux-amd64 ./cli\nGOOS=darwin GOARCH=arm64 go build -o jina-darwin-arm64 ./cli\nGOOS=windows GOARCH=amd64 go build -o jina-windows-amd64.exe ./cli\n```\n\n### 项目结构\n\n```\njina-cli/\n├── cli/\n│   ├── main.go          # 入口\n│   ├── read.go          # read 命令\n│   ├── search.go        # search 命令\n│   ├── config.go        # config 命令\n│   └── pkg/\n│       ├── api/         # HTTP 客户端\n│       ├── config/      # 配置管理\n│       └── output/      # 输出格式化\n└── scripts/\n    └── install.sh       # 安装脚本\n```\n\n### 许可证\n\n[MIT License](LICENSE)\n\n### 致谢\n\n- [Jina AI Reader API](https://github.com/jina-ai/reader) - 核心 API 服务\n- [md2wechat-lite](https://github.com/geekjourneyx/md2wechat-lite) - 项目架构参考\n\n---\n\n## 💰 打赏\n\n如果该项目帮助了您，欢迎请作者喝杯咖啡 ☕️\n\n**微信打赏**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/geekjourneyx/awesome-developer-go-sail/main/docs/assets/wechat-reward-code.jpg\" alt=\"微信打赏码\" width=\"200\" /\u003e\n\u003c/p\u003e\n\n---\n\n## 🧑‍💻 作者\n\n**[geekjourneyx](https://geekjourney.dev)**\n\n- **X (Twitter)**: https://x.com/seekjourney\n- **公众号**: 极客杰尼\n\n关注公众号，获取更多 AI 编程、AI 工具与 AI 出海建站的实战分享：\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/geekjourneyx/awesome-developer-go-sail/main/docs/assets/qrcode.jpg\" alt=\"公众号：极客杰尼\" width=\"180\" /\u003e\n\u003c/p\u003e\n\n---\n\n## English\n\n### Overview\n\n`jina` is a lightweight CLI tool that wraps the [Jina AI Reader API](https://github.com/jina-ai/reader) to convert any URL into LLM-friendly input. Perfect for reading X (Twitter), blogs, news sites, and other complex web pages.\n\n**Features:**\n\n- **read** - Extract content from URLs in Markdown/Text/HTML format\n- **search** - Search the web with AI-powered result processing\n\n---\n\n## Installation Guide\n\njina offers two independent installation methods. Choose based on your use case:\n\n### Method 1: Claude Code Skill (Recommended for AI-Assisted Development)\n\n**Use case**: Using jina within Claude Code with AI assistance\n\n**Installation steps**:\n\n```bash\n# 1. Ensure Node.js and Claude Code are installed\nnode --version\n# v18.0.0 or higher\n\n# 2. Install jina skill\nnpx skills add https://github.com/geekjourneyx/jina-cli --skill jina-cli\n```\n\n**Verify installation**:\n\n```bash\n# You can now use jina commands directly in Claude Code\n# No additional steps needed, skill loads automatically\n```\n\n**You get**:\n- ✅ Direct access to `jina read` and `jina search` commands in Claude Code\n- ✅ AI automatically understands jina's functionality\n- ✅ No manual CLI binary installation required\n\n---\n\n### Method 2: CLI Binary (Recommended for Terminal/Scripting)\n\n**Use case**: Using in terminal/scripts, or integrating with other tools\n\n#### One-line Installation (Linux/macOS)\n\n```bash\ncurl -fsSL https://raw.githubusercontent.com/geekjourneyx/jina-cli/main/scripts/install.sh | bash\n```\n\nThe installation script automatically:\n1. Detects your system architecture (Linux/macOS, amd64/arm64)\n2. Downloads the appropriate binary for your platform\n3. Installs to `~/.local/bin/jina` or `~/bin/jina`\n4. Prompts to add to PATH if needed\n\n#### Verify Installation\n\n```bash\n# Check if installation succeeded\njina --version\n# Expected output: jina version 1.0.0 (build: ..., commit: ...)\n\n# Test basic functionality\njina read --url \"https://example.com\"\n```\n\n#### Manual Installation\n\nIf auto-install fails, download manually:\n\n```bash\n# 1. Download binary for your platform\n# Linux amd64:\nwget https://github.com/geekjourneyx/jina-cli/releases/latest/download/jina-linux-amd64 -O jina\nchmod +x jina\nsudo mv jina /usr/local/bin/\n\n# macOS ARM64 (Apple Silicon):\nwget https://github.com/geekjourneyx/jina-cli/releases/latest/download/jina-darwin-arm64 -O jina\nchmod +x jina\nsudo mv jina /usr/local/bin/\n\n# 2. Verify installation\njina --version\n```\n\n#### Build from Source\n\n```bash\ngit clone https://github.com/geekjourneyx/jina-cli.git\ncd jina-cli\ngo build -o jina ./cli\nsudo mv jina /usr/local/bin/\n```\n\n---\n\n### Comparison\n\n| Feature | OpenClaw Skill | Claude Code Skill | CLI Binary |\n|---------|----------------|-------------------|------------|\n| **Install location** | `~/.openclaw/workspace/skills/jina-cli/` | `~/.claude/skills/` | `~/.local/bin/jina` |\n| **Environment** | OpenClaw local AI assistant | Claude Code | Any terminal/script |\n| **AI integration** | AI understands functionality | AI understands functionality | Manual invocation |\n| **File system access** | ✅ Full access | ❌ Limited | ✅ Full access |\n| **Script execution** | ✅ Can run scripts | ❌ Limited | ✅ Full access |\n| **Updates** | Re-download / `npx skills update` | `npx skills update` | Re-run install script |\n| **Best for** | Local AI assistant, automation | AI-assisted development | Script integration, daily use |\n\n**Recommendations**:\n- **OpenClaw** → Most capable, runs locally, full system access\n- **Claude Code** → Best dev experience, AI-assisted coding\n- **CLI Binary** → Lightweight, perfect for scripts\n\n**Note**: The three methods are completely independent. Install any or all without conflicts.\n\n---\n\n### Quick Start\n\n#### Read Web Content\n\n```bash\n# Read a single URL\njina read --url \"https://example.com\"\n\n# Read X (Twitter) post\njina read -u \"https://x.com/user/status/123456789\" --with-alt\n\n# Output as Markdown\njina read -u \"https://example.com\" --output markdown\n\n# Save to file\njina read -u \"https://example.com\" --output-file result.md\n```\n\n#### Batch Processing\n\n```bash\n# Read from URL list file\ncat \u003e urls.txt \u003c\u003c EOF\nhttps://example.com/page1\nhttps://example.com/page2\nhttps://x.com/user/status/123\nEOF\n\njina read --file urls.txt\n```\n\n#### Web Search\n\n```bash\n# Search for a query\njina search --query \"golang latest news\"\n\n# Restrict to specific sites\njina search -q \"AI developments\" --site techcrunch.com --site theverge.com\n\n# Limit results\njina search -q \"climate change\" --limit 10\n```\n\n### Configuration\n\nConfig file location: `~/.jina-reader/config.yaml`\n\n```bash\n# List all configuration\njina config list\n\n# Set configuration\njina config set timeout 60\njina config set with-generated-alt true\n\n# Get single configuration\njina config get timeout\n\n# Show config file path\njina config path\n```\n\n### Configuration Options\n\n| Key | Env Var | Default | Description |\n|-----|---------|---------|-------------|\n| `api_base_url` | `JINA_API_BASE_URL` | `https://r.jina.ai/` | Read API URL |\n| `search_api_url` | `JINA_SEARCH_API_URL` | `https://s.jina.ai/` | Search API URL |\n| `default_response_format` | `JINA_RESPONSE_FORMAT` | `markdown` | Response format |\n| `default_output_format` | `JINA_OUTPUT_FORMAT` | `json` | Output format |\n| `timeout` | `JINA_TIMEOUT` | `30` | Request timeout (seconds) |\n| `with_generated_alt` | `JINA_WITH_GENERATED_ALT` | `false` | Enable image captioning |\n| `proxy_url` | `JINA_PROXY_URL` | `\"\"` | Proxy server |\n| `api_key` | `JINA_API_KEY` | `\"\"` | API key for higher rate limits |\n\n**Priority:** CLI args \u003e Env vars \u003e Config file \u003e Defaults\n\n### API Key Usage\n\nAdding an API key provides higher rate limits:\n\n```bash\n# Method 1: Set via config file\njina config set api_key jina_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n\n# Method 2: Set via environment variable\nexport JINA_API_KEY=jina_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n\n# Method 3: Pass via command line\njina read -u \"https://example.com\" -k jina_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\n```\n\nGet your API key: Visit [Jina AI Reader](https://jina.ai/reader/#apiform) to sign up.\n\n### Output Formats\n\n#### JSON Format (Default)\n\n```json\n{\n  \"success\": true,\n  \"data\": {\n    \"url\": \"https://example.com\",\n    \"title\": \"Example Domain\",\n    \"content\": \"# Example Domain\\n\\nThis domain is...\"\n  }\n}\n```\n\n#### Markdown Format\n\n```bash\njina read -u \"https://example.com\" --output markdown\n```\n\nOutput:\n```markdown\n# Example Domain\n\n**Source**: https://example.com\n\n---\n\n# Example Domain\n\nThis domain is for use in illustrative examples...\n```\n\n### Advanced Usage\n\n#### Bypass Cache\n\n```bash\njina read -u \"https://example.com\" --no-cache\n```\n\n#### Use Proxy\n\n```bash\njina read -u \"https://example.com\" --proxy \"http://proxy.com:8080\"\n```\n\n#### CSS Selector Extraction\n\n```bash\n# Extract specific element only\njina read -u \"https://example.com\" --target-selector \"article.main\"\n\n# Wait for element to load\njina read -u \"https://example.com\" --wait-for-selector \"#content\"\n```\n\n#### Handle SPA Apps\n\n```bash\n# For SPA with hash routing, use POST method\njina read -u \"https://example.com/#/route\" --post\n```\n\n#### Set Cookie\n\n```bash\njina read -u \"https://example.com\" --cookie \"session=abc123\"\n```\n\n### AI Agent Integration\n\n```bash\n# Use with Claude Code or other AI tools\njina read -u \"https://x.com/elonmusk/status/123456\" --output json\n\n# Search for latest information\njina search -q \"golang 1.24 release notes\" --output json\n```\n\n### Command Reference\n\n```\njina - CLI tool for Jina AI Reader and Search APIs\n\nUsage:\n  jina [command]\n\nAvailable Commands:\n  read        Extract and convert content from URLs\n  search      Search the web with AI-powered results\n  config      Manage configuration\n  completion  Generate shell completion\n  help        Help about any command\n\nFlags:\n  -a, --api-base string   API base URL (overrides config)\n  -k, --api-key string    API key (overrides config)\n  -o, --output string     Output format: json, markdown (default \"json\")\n  -v, --verbose           Verbose output\n  -h, --help              help for jina\n      --version           version for jina\n```\n\n### Development\n\n```bash\n# Run tests\ngo test ./...\n\n# Run tests with coverage\ngo test -cover ./...\n\n# Build\ngo build -o jina ./cli\n\n# Cross-compile\nGOOS=linux GOARCH=amd64 go build -o jina-linux-amd64 ./cli\nGOOS=darwin GOARCH=arm64 go build -o jina-darwin-arm64 ./cli\nGOOS=windows GOARCH=amd64 go build -o jina-windows-amd64.exe ./cli\n```\n\n### License\n\n[MIT License](LICENSE)\n\n### Acknowledgments\n\n- [Jina AI Reader API](https://github.com/jina-ai/reader) - Core API service\n- [md2wechat-lite](https://github.com/geekjourneyx/md2wechat-lite) - Architecture reference\n\n---\n\n## 💰 Sponsor\n\nIf this project helped you, consider buying me a coffee ☕️\n\n**WeChat Pay**\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/geekjourneyx/awesome-developer-go-sail/main/docs/assets/wechat-reward-code.jpg\" alt=\"WeChat Pay QR Code\" width=\"200\" /\u003e\n\u003c/p\u003e\n\n---\n\n## 👨‍💻 Author\n\n**[geekjourneyx](https://geekjourney.dev)**\n\n- **X (Twitter)**: https://x.com/seekjourney\n- **WeChat Official Account**: 极客杰尼 (Geek Journey)\n\nFollow for more insights on AI coding, AI tools, and AI-powered global website building:\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/geekjourneyx/awesome-developer-go-sail/main/docs/assets/qrcode.jpg\" alt=\"WeChat Official Account: Geek Journey\" width=\"180\" /\u003e\n\u003c/p\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeekjourneyx%2Fjina-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgeekjourneyx%2Fjina-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeekjourneyx%2Fjina-cli/lists"}