A Docker-based GitHub Action for running iFlow CLI commands
GitHub: iflow-ai/iflow-cli-action
Docker-based Action with pre-installed Node.js 22, npm, go, cargo, and uv
Configurable Authentication with iFlow API
MCP Server Support for enhanced capabilities
Agent Client Protocol using Rust ACP Websocket client
Custom Models and API endpoints support
GitHub Actions Summary integration for rich reports
详细安装指南请参阅 Authentication Section
name: 'iFLOW CLI Basic Example'
on:
workflow_dispatch:
jobs:
basic-example:
runs-on: 'ubuntu-latest'
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: 'Run iFlow CLI'
uses: iflow-ai/iflow-cli-action@v2.0.0
with:
api_key: ${{ secrets.IFLOW_API_KEY }}
prompt: "Analyze this codebase for security issues"
- name: iFlow CLI with MCP Server
uses: iflow-ai/iflow-cli-action@v2.0.0
with:
prompt: "use @deepwiki to search how to use Skynet to build a game"
api_key: ${{ secrets.IFLOW_API_KEY }}
settings_json: |
{
"selectedAuthType": "iflow",
"apiKey": "${{ secrets.IFLOW_API_KEY }}",
"baseUrl": "https://apis.iflow.cn/v1",
"modelName": "Qwen3-Coder",
"searchApiKey": "${{ secrets.IFLOW_API_KEY }}",
"mcpServers": {
"deepwiki": {
"command": "npx",
"args": ["-y", "mcp-deepwiki@latest"]
}
}
}
model: "Qwen3-Coder"
timeout: "1800"
debug: "true"
- name: iFlow with Pre-Execution Commands
uses: iflow-ai/iflow-cli-action@v2.0.0
with:
prompt: "Analyze this codebase after installing dependencies"
api_key: ${{ secrets.IFLOW_API_KEY }}
precmd: |
npm install
git fetch origin main
- name: iFlow CLI with Custom Versions
uses: iflow-ai/iflow-cli-action@v2.0.0
with:
prompt: "Analyze this codebase with specific tool versions"
api_key: ${{ secrets.IFLOW_API_KEY }}
gh_version: "2.76.2"
iflow_version: "0.2.4"
查看 examples 目录 获取详细示例
| 输入 | 描述 | 必需 | 默认值 |
|---|---|---|---|
| prompt | 要执行的 iFlow CLI 提示 | ✅ | - |
| api_key | iFlow API 认证密钥 | ✅ | - |
| timeout | 执行超时时间(秒) | ❌ | 86400 |
| precmd | 执行前的 shell 命令 | ❌ |
| 输出 | 描述 |
|---|---|
| result | iFlow CLI 执行结果 |
| exit_code | iFlow CLI 执行退出码 |
timeout 值以处理复杂操作
timeout: "900" # 15 minutes
env:
ACTIONS_STEP_DEBUG: true
感谢您关注 iFlow CLI GitHub Action!