← スキル一覧に戻る

json-schema
by beshkenadze
A marketplace of Claude Agent Skills - organized packages of instructions, scripts, and resources that extend Claude's capabilities
⭐ 0🍴 0📅 2026年1月25日
SKILL.md
name: json-schema description: Generate and validate JSON Schema definitions. Use when asked to create schemas, validate JSON structure, or document API payloads. version: 1.0.0
JSON Schema Generator
Overview
Creates JSON Schema definitions for data validation and API documentation.
Instructions
When generating JSON Schema:
- Analyze the data structure or requirements
- Determine types for each field (string, number, object, array, etc.)
- Add constraints: required fields, patterns, min/max values
- Include descriptions for documentation
- Set appropriate
$schemaversion (draft-07 recommended)
Schema Components
Basic Types
string- Text valuesnumber/integer- Numeric valuesboolean- True/falseobject- Nested structuresarray- Lists of itemsnull- Null values
Common Constraints
required- Mandatory fieldsminLength/maxLength- String lengthminimum/maximum- Number boundspattern- Regex validationenum- Allowed valuesformat- Semantic formats (email, uri, date-time)
Examples
Example: User Schema
Input: "Create a schema for a user with name, email, age, and optional phone"
Output:
{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "User",
"type": "object",
"required": ["name", "email", "age"],
"properties": {
"name": {
"type": "string",
"minLength": 1,
"maxLength": 100,
"description": "User's full name"
},
"email": {
"type": "string",
"format": "email",
"description": "User's email address"
},
"age": {
"type": "integer",
"minimum": 0,
"maximum": 150,
"description": "User's age in years"
},
"phone": {
"type": "string",
"pattern": "^\\+?[1-9]\\d{1,14}$",
"description": "Optional phone number in E.164 format"
}
},
"additionalProperties": false
}
Guidelines
Do
- Always include
$schemadeclaration - Add descriptions for all properties
- Use
additionalProperties: falsefor strict validation - Prefer specific formats over loose patterns
- Use
requiredarray for mandatory fields
Don't
- Use overly permissive types (avoid
{}ortrue) - Skip validation constraints on user input
- Mix draft versions in same schema
- Forget to handle nullable fields explicitly
スコア
総合スコア
60/100
リポジトリの品質指標に基づく評価
✓SKILL.md
SKILL.mdファイルが含まれている
+20
○LICENSE
ライセンスが設定されている
0/10
✓説明文
100文字以上の説明がある
+10
○人気
GitHub Stars 100以上
0/15
○最近の活動
3ヶ月以内に更新がある
0/10
○フォーク
10回以上フォークされている
0/5
✓Issue管理
オープンIssueが50未満
+5
✓言語
プログラミング言語が設定されている
+5
○タグ
1つ以上のタグが設定されている
0/5
レビュー
💬
レビュー機能は近日公開予定です