58pic

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese
本 Skill 与仓库根目录 README.md 保持一致;实际请求由终端中的
58pic
命令发出
,Agent 应通过 执行 shell 命令 调用,而不是在对话里伪造 HTTP。
This Skill is consistent with the README.md in the repository root directory; actual requests are sent by the
58pic
command in the terminal
, the Agent should call it by executing shell commands instead of forging HTTP requests in conversations.

Agent Skills 安装

Agent Skills Installation

使用开源 skills CLI
npx skills
)将仓库内
skills/
安装到 Cursor、Claude Code、Codex 等 Agent 目录:
bash
npm install -g @58pic/cli
npx skills add 58pic-open/cli -y -g
查看本仓库提供的 Skill 列表(不安装):
npx skills add 58pic-open/cli --list

仅安装本 Skill:
npx skills add 58pic-open/cli --skill 58pic -y -g

亦可使用完整仓库地址
https://github.com/58pic-open/cli
须先安装
58pic
可执行文件
npm install -g @58pic/cli
npm install -g github:58pic-open/cli
);Skill 不会替代 CLI,只指导 Agent 如何调用命令行。
千图 AI 开放平台 使用 API Key 认证,无 OAuth 浏览器流程。CLI 提供
config init
auth status
dry-run
等常用能力。
Use the open source skills CLI (
npx skills
) to install
skills/
in the repository to Agent directories such as Cursor, Claude Code, Codex, etc.:
bash
npm install -g @58pic/cli
npx skills add 58pic-open/cli -y -g
View the Skill list provided by this repository (no installation):
npx skills add 58pic-open/cli --list

Install this Skill only:
npx skills add 58pic-open/cli --skill 58pic -y -g

You can also use the full repository address
https://github.com/58pic-open/cli
.
You must install the
58pic
executable first
(
npm install -g @58pic/cli
or
npm install -g github:58pic-open/cli
); Skill does not replace CLI, it only guides the Agent on how to call the command line.
58pic AI Open Platform uses API Key for authentication, no OAuth browser process. CLI provides common capabilities such as
config init
,
auth status
,
dry-run
, etc.

缺少 API Key 时(Agent 必提醒用户)

When API Key is missing (Agent must remind users)

58pic auth status
显示未配置、或命令报错提示缺少 API Key:不要猜测或编造 Key
获取 API Key(须先登录): 千图 AI 开放平台
用户取得 Key 后,再执行
58pic config init --api-key "<用户的 Key>"
(或交互式
58pic config init
)。勿把 Key 写入可被提交的仓库。
If
58pic auth status
shows unconfigured, or the command reports an error indicating missing API Key: Do not guess or fabricate the Key.
Get API Key (login required first): 58pic AI Open Platform
After the user gets the Key, execute
58pic config init --api-key "<user's Key>"
(or interactive
58pic config init
). Do not write the Key into a repository that can be submitted.

调用方式(Agent 必做)

Calling Method (Agent must follow)

  1. 确认已安装:
    58pic --help
    (失败则按 README 执行
    npm install -g @58pic/cli
    github:58pic-open/cli
    )。
  2. 确认凭证:
    58pic auth status
    若无 Key,必须先按上文「缺少 API Key 时」引导用户获取,再
    58pic config init --api-key "<key>"
    (勿把 Key 写入可被提交的仓库)。
  3. 自动化解析响应时加
    --format json
  4. 可能扣点的接口(下载、做同款等)先用
    58pic dry-run …
    或提醒用户确认。
  1. Confirm installation:
    58pic --help
    (if it fails, execute
    npm install -g @58pic/cli
    or
    github:58pic-open/cli
    according to README).
  2. Confirm credentials:
    58pic auth status
    ; If there is no Key, you must first guide the user to obtain it according to the above "When API Key is missing" section, then run
    58pic config init --api-key "<key>"
    (do not write the Key into a repository that can be submitted).
  3. Add
    --format json
    when automatically parsing responses.
  4. For interfaces that may deduct points (download, create same style, etc.), use
    58pic dry-run …
    first or remind users to confirm.

常用命令

Common Commands

场景命令
关键词搜索
58pic search "关键词" --format json
AI 向量搜索
58pic search --ai --format json
分类目录
58pic catalog --format json
模型列表
58pic models --format json
按 pid 拉取下载信息
58pic download <pid> --format json
做同款
58pic same-style --help
(需
-m/--model
,复杂 body 用
--body-file
任务状态
58pic same-style-status <ai_id> --format json
未封装路由
58pic api <route> --body '{...}'
--body-file
凭证优先级与环境变量
58PIC_API_KEY
58PIC_BASE_URL
见 README(注意 bash/zsh 无法
export
以数字开头的变量名,本地优先配置文件或
--api-key
)。
ScenarioCommand
Keyword search
58pic search "keyword" --format json
AI vector search
58pic search --ai --format json
Category directory
58pic catalog --format json
Model list
58pic models --format json
Fetch download information by pid
58pic download <pid> --format json
Create same style
58pic same-style --help
(requires
-m/--model
, use
--body-file
for complex body)
Task status
58pic same-style-status <ai_id> --format json
Unencapsulated route
58pic api <route> --body '{...}'
or
--body-file
Credential priority and environment variables
58PIC_API_KEY
,
58PIC_BASE_URL
are described in README (note that bash/zsh cannot
export
variable names starting with numbers, local configuration files or
--api-key
are preferred).

安全

Security

API Key 等同账号能力:限制暴露范围,勿在不可信环境明文传递;自动化调用可能扣点的接口前须让用户知情或确认。
API Key has the same permissions as the account: limit the exposure scope, do not transmit it in plain text in untrusted environments; users must be informed or confirmed before automatically calling interfaces that may deduct points.