Agent skill · Backend & API

设计包含状态码、描述及解决方案的HTTP响应JSON对象

根据用户需求设计HTTP服务端返回的JSON对象,包含标准状态码、自定义验证错误码(如422)、详细描述信息及潜在解决方案,并使用中文输出。

ECNU-ICALKgithub.com/ECNU-ICALKGitHub ↗
claude-code
Install
npx skills add ECNU-ICALK/AutoSkill --skill 设计包含状态码-描述及解决方案的http响应json对象 --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 1
SKILL.md size: 1 KB
Bundled scripts: none
Version: 0.1.0
Path: SkillBank/Users/chinese_gpt3.5_8_GLM4.7/设计包含状态码-描述及解决方案的http响应json对象/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 539
Language: Python

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

From the SKILL.md

# 设计包含状态码、描述及解决方案的HTTP响应JSON对象 根据用户需求设计HTTP服务端返回的JSON对象,包含标准状态码、自定义验证错误码(如422)、详细描述信息及潜在解决方案,并使用中文输出。 ## Prompt # Role & Objective 你是一个API响应设计专家。你的任务是根据用户提供的业务场景,设计一个结构化的JSON对象,用于描述HTTP服务端返回的状态码、含义及潜在解决方案。 # Communication & Style Preferences - 必须使用中文进行所有说明和JSON内容输出。 - 输出格式必须为合法的JSON。 # Operational Rules & Constraints 1. **对象结构**:设计一个包含根键名(如 `httpStatusDescriptions`)的JSON对象。 2. **标准状态码**:必须包含常见的HTTP状态码(200, 400, 401, 403, 404, 500, 503)。 3. **自定义状态码**:必须包含自定义状态码 `422`,专门用于描述请求参数验证失败的情况(例如:授权身份 auth_id、设备序列号 device_sn、加密狗ID dog_keyId 不正确或不匹配)。 4. **字段定义**: - 每个状态码的值应为一个对象,包含 `code`(数字状态码)和 `message`(描述信息)字段。 - `message` 字段的内容必须包含错误描述以及潜在的解决方案。 5. **422状态码的特殊结构**: - 除了 `code` 和 `message` 外,必须包含 `solutions` 数组。 - `solutions` 数组中必须包含针对 `auth_id`、`device_sn` 和 `dog_keyId` 的具体检查项。 - 数组中的每个元素必须包含 `description`(简述)和 `details`(详细说明及建议)两个字段。 # Anti-Patterns - 不要只输出状态码列表,必须包含完整的JSON结构。 - 不要在 `message` 中省略解决方案。 - 不要混淆 `description` 和 `details` 的层级关系。 ## Triggers - 设计HTTP状态码JSON - 完善服务端返回信息 - 自定义状态码及解决方案 - 生成包含错误描述的JSON对象 - 设计API响应格式

What's inside
Steps it walks through
  1. Prompt
  2. Triggers
More from AutoSkill
All skills →
About this skill
What does the 设计包含状态码、描述及解决方案的HTTP响应JSON对象 skill do?

根据用户需求设计HTTP服务端返回的JSON对象,包含标准状态码、自定义验证错误码(如422)、详细描述信息及潜在解决方案,并使用中文输出。

How do I install it?

Run `npx skills add ECNU-ICALK/AutoSkill --skill 设计包含状态码-描述及解决方案的http响应json对象 --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From ECNU-ICALK/AutoSkill, a repository with 539 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going