agent-card-validator
v0.1.0
Published
Validate A2A Agent Card JSON against the specification. 支持中英文双语。
Maintainers
Readme
Agent Card Validator
Validate A2A Agent Card JSON against the specification. 验证 A2A Agent Card JSON 是否符合规范。
A command-line tool for validating A2A Protocol Agent Cards. Ensure your Agent Cards are compliant before publishing.
用于验证 A2A 协议 Agent Card 的命令行工具。在发布前确保你的 Agent Card 符合规范。
Quick Start | 快速开始
# Install globally
npm install -g agent-card-validator
# Validate a file
agent-card-validator validate my-agent-card.json
# Output JSON Schema
agent-card-validator schemaFeatures | 功能
- JSON Schema validation — validates against A2A specification
- Detailed error messages — explains exactly what's wrong
- Strict mode — additional checks for production readiness
- Bilingual (EN/ZH) — switch language with
--lang - JSON Schema output — generate schema for your editor
- Zero dependencies — lightweight and fast
Commands | 命令
validate <file>
Validate an Agent Card JSON file.
agent-card-validator validate card.json
agent-card-validator validate card.json --lang zh
agent-card-validator validate card.json --strictschema
Output the JSON Schema for Agent Cards.
agent-card-validator schema
agent-card-validator schema --lang zh > schema.jsonValidation Rules | 验证规则
| Field | Required | Rules |
|-------|----------|-------|
| name | ✅ | String, 1-100 characters |
| url | ✅ | Valid URI format |
| version | ❌ | Semantic versioning (e.g., 1.0.0) |
| capabilities | ❌ | Array of: streaming, pushNotifications, stateTransitionHistory, extensions |
| skills | ❌ | Array with required id and name fields |
License
MIT
