Token导航 LogoToken导航TokenDH.com
AI 工具敏感数据github未标认证来源可访问clear审计异常

restapirestapi 命令行

Agent Skill

restapi 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

964

周安装

39

GitHub Stars

11

下载量

303
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:restapi(restapi 命令行)
来源仓库:https://github.com/lobbi-docs/claude
仓库路径:skills/restapi
安装命令:
npx skills add https://github.com/lobbi-docs/claude --skill restapi
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/lobbi-docs/claude --skill restapi

简介

用于处理 GitHub 仓库和代码协作信息。

  • 支持 Issue、PR 和仓库状态管理。
  • 可结合来源仓库核验具体用法。restapi 属于AI 工具类 Skill,可作为该场景下的辅助能力补充。
  • 需确认权限范围和文件读写权限。适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。
  • 适合代码变更跟踪和协作事项整理。

SKILL.md

REST API Skill

Provides comprehensive REST API design and implementation capabilities for the Golden Armada AI Agent Fleet Platform.

When to Use This Skill

Activate this skill when working with:

  • API endpoint design
  • HTTP request/response handling
  • API authentication
  • OpenAPI documentation
  • API testing

REST API Design Principles

Resource Naming


# Good - nouns, plural

GET /agents GET /agents/{id} POST /agents PUT /agents/{id} DELETE /agents/{id}

# Nested resources

GET /agents/{id}/tasks POST /agents/{id}/tasks

# Bad - verbs, actions

GET /getAgents POST /createAgent ```

### HTTP Methods

| Method | Usage | Idempotent |
| --- | --- | --- |
| GET | Read resource | Yes |
| POST | Create resource | No |
| PUT | Replace resource | Yes |
| PATCH | Partial update | No |
| DELETE | Delete resource | Yes |

### Status Codes

Success

200 OK - Successful GET, PUT, PATCH 201 Created - Successful POST 204 No Content - Successful DELETE

Client Errors

400 Bad Request - Validation error 401 Unauthorized - Authentication required 403 Forbidden - Not permitted 404 Not Found - Resource not found 409 Conflict - Duplicate/conflict 422 Unprocessable - Semantic validation error

Server Errors

500 Internal Error - Server error 502 Bad Gateway - Upstream error 503 Service Unavailable - Temporary overload ```

API Implementation (FastAPI)


app = FastAPI(title="Golden Armada API", version="1.0.0")

# Models

class AgentCreate(BaseModel): name: str = Field(..., min_length=1, max_length=100) type: str = Field(..., pattern="^(claude|gpt|gemini)$")

class AgentResponse(BaseModel): id: str name: str type: str status: str created_at: datetime

# Endpoints

@app.get("/agents", response_model=List[AgentResponse]) async def list_agents(skip: int = Query(0, ge=0), limit: int = Query(100, ge=1, le=1000), status: Optional[str] = Query(None)): """List all agents with pagination and filtering.""" return await agent_service.list(skip=skip, limit=limit, status=status)

@app.get("/agents/{agent_id}", response_model=AgentResponse) async def get_agent(agent_id: str = Path(..., description="Agent ID")): """Get a specific agent by ID.""" agent = await agent_service.get(agent_id) if not agent: raise HTTPException(status_code=404, detail="Agent not found") return agent

@app.post("/agents", response_model=AgentResponse, status_code=201) async def create_agent(agent: AgentCreate): """Create a new agent.""" return await agent_service.create(agent)

@app.put("/agents/{agent_id}", response_model=AgentResponse) async def update_agent(agent_id: str, agent: AgentCreate): """Replace an existing agent.""" existing = await agent_service.get(agent_id) if not existing: raise HTTPException(status_code=404, detail="Agent not found") return await agent_service.update(agent_id, agent)

@app.delete("/agents/{agent_id}", status_code=204) async def delete_agent(agent_id: str): """Delete an agent.""" deleted = await agent_service.delete(agent_id) if not deleted: raise HTTPException(status_code=404, detail="Agent not found") ```

## Authentication

### JWT Authentication

oauth2_scheme = OAuth2PasswordBearer(tokenUrl="token")

async def get_current_user(token: str = Depends(oauth2_scheme)): credentials_exception = HTTPException(status_code=status.HTTP_401_UNAUTHORIZED, detail="Could not validate credentials", headers={"WWW-Authenticate": "Bearer"},) try: payload = jwt.decode(token, SECRET_KEY, algorithms=[ALGORITHM]) user_id: str = payload.get("sub") if user_id is None: raise credentials_exception except JWTError: raise credentials_exception return await get_user(user_id)

Protected endpoint

@app.get("/protected") async def protected_route(user: User = Depends(get_current_user)): return {"user": user.email} ```

API Key Authentication


api_key_header = APIKeyHeader(name="X-API-Key")

async def verify_api_key(api_key: str = Depends(api_key_header)): if api_key!= VALID_API_KEY: raise HTTPException(status_code=403, detail="Invalid API key") return api_key ```

## Error Handling

@app.exception_handler(ValueError) async def value_error_handler(request, exc): return JSONResponse(status_code=400, content=ErrorResponse(error="validation_error", message=str(exc)).dict())

@app.exception_handler(Exception) async def general_exception_handler(request, exc): return JSONResponse(status_code=500, content=ErrorResponse(error="internal_error", message="An unexpected error occurred").dict()) ```

API Testing with curl


# GET

curl -X GET "[http://localhost:8000/agents](http://localhost:8000/agents)" -H "Authorization: Bearer TOKEN"

# POST

curl -X POST "[http://localhost:8000/agents](http://localhost:8000/agents)" -H "Content-Type: application/json" -H "Authorization: Bearer TOKEN" -d '{"name": "agent-1", "type": "claude"}'

# PUT

curl -X PUT "[http://localhost:8000/agents/123](http://localhost:8000/agents/123)" -H "Content-Type: application/json" -d '{"name": "updated-agent", "type": "claude"}'

# DELETE

curl -X DELETE "[http://localhost:8000/agents/123](http://localhost:8000/agents/123)" -H "Authorization: Bearer TOKEN" ```

## OpenAPI Documentation

app = FastAPI(title="Golden Armada API", description="AI Agent Fleet Platform API", version="1.0.0", docs_url="/docs", redoc_url="/redoc", openapi_url="/openapi.json")

Access documentation at:

- Swagger UI: http://localhost:8000/docs

- ReDoc: http://localhost:8000/redoc

- OpenAPI JSON: http://localhost:8000/openapi.json

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Claude Code

30.48%
按下载量换算92

Gemini CLI

21.53%
按下载量换算65

Antigravity

15.6%
按下载量换算47

windsurf

12.57%
按下载量换算38

Codex

7.04%
按下载量换算21

OpenCode

3.4%
按下载量换算10

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

未通过

权限和风险

敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。

来源信息

继续浏览同类 Skills