返回顶部
a

apixAPI端点搜索

Use `apix` to search, browse, and execute API endpoints from local markdown vaults. Use this skill to discover REST API endpoints, inspect request/response schemas, and make HTTP calls directly from the terminal without leaving your environment.

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
320
下载量
免费
免费
0
收藏
概述
安装方式
版本历史

apix

apix — API 探索工具(面向智能体)

apix 是一个命令行工具,用于导入、浏览、搜索和调用以本地 Markdown 仓库形式存储的 API 端点文档。

前提条件与安装

使用 apix 之前,请确认是否已安装:

bash
apix --version

如果尚未安装,可通过 Homebrew(macOS/Linux)安装:

bash
brew tap apix-sh/tap
brew install apix

或通过 curl 安装脚本:

bash
curl -fsSL https://apix.sh/install | sh

智能体工作流程指南

当收到 API 任务请求时,请遵循以下通用工作流程:

  1. 1. 发现:找到相关的端点路由。

bash
apix search create pet
# 或列出可用 API:apix ls

  1. 2. 查看:简洁地检查端点参数和模式,以节省上下文窗口。

bash
apix peek petstore/v1/pets/{petId}/GET

注意:仅当你需要完整、详细的文档时才使用 apix show ,因为它可能内容较长。

  1. 3. 执行:使用找到的路由发起 HTTP 调用。
bash apix call demo/v1/items/{id}/POST -p id=item_123 -d {name:item}

核心命令

搜索与发现

  • - 在所有已索引的 API 中搜索:apix search
  • 列出命名空间:apix ls
  • 列出命名空间中的端点:apix ls /(例如 apix ls petstore/v1)
  • 在命名空间内进行全文搜索:apix grep

检查端点

路由遵循以下格式:///(例如 petstore/v1/pets/GET)。

  • - 快速查看(推荐智能体使用):apix peek — 输出 YAML 前置元数据和精简的必填输入字段。
  • 完整显示:apix show — 输出该路由或类型的完整 Markdown 文档。

执行 HTTP 调用

apix call 会自动从路由的 Markdown 前置元数据中解析 URL、方法和认证要求。

  • - 使用字面路径段的基本调用

bash
apix call demo/v1/items/item_123/GET

(如果定义的路由是 demo/v1/items/{id}/GET,apix 会自动将 item123 映射到 {id} 参数)_

  • - 显式参数

bash
apix call demo/v1/items/{id}/POST \
-p id=item_123 \
-q expand=full \
-H Authorization: Bearer \
-d {name:item}

- -p =:路径参数
- -q =:查询参数
- -H

: :HTTP 头部
- -d 或 -d @file.json:请求体

导入自定义规范

如果所需的 API 不在公共注册表中,你可以在本地导入 OpenAPI 3.x 规范:

bash
apix import /path/to/openapi.json --name myapi

智能体注意事项

  • - 当你通过 shell 执行 apix 命令时,它会检测到标准输出被管道化,并自动输出原始 Markdown,这非常适合你阅读。
  • apix 路由是标准字符串。如果某个路由匹配多个来源,apix 会抛出歧义错误。此时,请在路由前加上来源前缀(例如 core/petstore/v1/pets/GET)。
  • 优先使用 peek 而非 show,以避免用冗余的模式信息淹没你的上下文窗口。

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 apix-1776209728 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 apix-1776209728 技能

通过命令行安装

skillhub install apix-1776209728

下载

⬇ 下载 apix v1.0.0(免费)

文件大小: 2.15 KB | 发布时间: 2026-4-15 12:59

v1.0.0 最新 2026-4-15 12:59
Initial publish.

apix is a local-first, progressive disclosure CLI tool for agents and humans to explore, browser and call API endpoints. Use this skill to discover REST API endpoints, inspect request/response schemas, and make HTTP calls directly from the terminal without leaving your environment.

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部