This directory contains example JSON files for registering A2A agents using the agent management CLI.
The agent management CLI uses the mcp-gateway-m2m service account for all operations.
Token Details:
- Service Account ID:
mcp-gateway-m2m - Token Location:
.oauth-tokens/ingress.json - Token Generation:
./credentials-provider/generate_creds.sh - Required Keycloak Groups:
mcp-servers-unrestricted(for MCP server access)a2a-agent-admin(for agent management permissions)
Start the registry service in one terminal:
python -m uvicorn registry.main:app --reloadWait for: Uvicorn running on http://127.0.0.1:8000
In another terminal, the agent management CLI will automatically use the mcp-gateway-m2m token from .oauth-tokens/ingress.json:
# Register the test code reviewer agent
# Token is automatically loaded from .oauth-tokens/ingress.json (mcp-gateway-m2m service account)
uv run python cli/agent_mgmt.py register cli/examples/test_code_reviewer_agent.json# List all agents
uv run python cli/agent_mgmt.py list
# Get specific agent details
uv run python cli/agent_mgmt.py get /test-reviewer
# Test agent accessibility
uv run python cli/agent_mgmt.py test /test-reviewerAll example files use the complete A2A agent schema with all fields documented:
Comprehensive code review agent analyzing code quality, bugs, and improvements.
Skills:
- Analyze Code Quality
- Detect Bugs
- Suggest Improvements
Security: JWT Bearer token authentication Features: Streaming enabled, verified trust level
Usage:
uv run python cli/agent_mgmt.py register cli/examples/code_reviewer_agent.jsonIntelligent test automation agent for generating and executing test cases.
Skills:
- Generate Unit Tests
- Execute Tests
- Analyze Test Coverage
- Generate Test Report
Security: API Key + OAuth2 authentication Features: Streaming enabled, community trust level
Usage:
uv run python cli/agent_mgmt.py register cli/examples/test_automation_agent.jsonAdvanced data analysis agent for statistical analysis and visualization.
Skills:
- Statistical Analysis
- Data Visualization
- Predictive Modeling
- Anomaly Detection
- Data Transformation
Security: JWT Bearer + OpenID Connect Features: GPU-enabled, verified trust level, supports large datasets
Usage:
uv run python cli/agent_mgmt.py register cli/examples/data_analysis_agent.jsonComprehensive security analysis agent for vulnerability detection and compliance.
Skills:
- Scan for Vulnerabilities
- Check Compliance
- Analyze Authentication
- Penetration Testing
- Generate Security Report
Security: Mutual TLS + API Key authentication Features: Trusted level, comprehensive CVE database
Usage:
uv run python cli/agent_mgmt.py register cli/examples/security_analyzer_agent.jsonDocumentation agent for generating and maintaining API docs and guides.
Skills:
- Generate API Documentation
- Extract and Format Docstrings
- Generate README
- Maintain Documentation
- Generate Changelog
Security: Basic Auth + API Token Features: Supports multiple documentation formats, community trust level
Usage:
uv run python cli/agent_mgmt.py register cli/examples/documentation_agent.jsonDevOps automation agent for infrastructure and deployment management.
Skills:
- Deploy Application
- Manage Infrastructure
- Configure CI/CD Pipeline
- Monitor Health and Performance
- Manage Secrets and Credentials
- Auto-Scale Application
Security: AWS SigV4 + Client Certificate Features: Multi-cloud support, verified trust level
Usage:
uv run python cli/agent_mgmt.py register cli/examples/devops_deployment_agent.jsonAll example files include the complete A2A agent schema:
Required Fields:
protocol_version: A2A protocol version (e.g., "1.0")name: Agent display namedescription: What the agent doesurl: Agent endpoint URLpath: Registry path (must start with/)
Optional A2A Fields:
version: Semantic versionprovider: Agent provider/authorsecurity_schemes: Authentication methods (http, apiKey, oauth2, openIdConnect)security: Security requirements arrayskills: Array of capabilities with parametersstreaming: Supports streaming responses (boolean)metadata: Additional metadata key-value pairs
Registry Extensions:
tags: Array of categorization tagsis_enabled: Whether agent is enablednum_stars: Community ratinglicense: License informationvisibility: "public", "private", or "group-restricted"allowed_groups: Groups with access (for group-restricted)trust_level: "unverified", "community", "verified", or "trusted"registered_at: Registration timestamp (auto-set)updated_at: Last update timestamp (auto-set)registered_by: Username who registered (auto-set)signature: JWS signature for integrity
Federation & Lifecycle Metadata (New):
status: Lifecycle status - "active", "beta", "draft", or "deprecated"provider: Provider information object with:organization: Provider organization nameurl: Provider website or documentation URL
source_created_at: Original creation timestamp from source system (ISO 8601 format)source_updated_at: Last update timestamp from source system (ISO 8601 format)
For reference implementations showing all available fields including the new federation and lifecycle metadata:
complete-server-example.json
- Shows all server configuration fields
- Includes lifecycle status, provider info, federation timestamps
- Demonstrates custom metadata usage
complete-agent-example.json
- Shows all agent configuration fields
- Includes lifecycle status, provider info, federation timestamps
- Full agent card schema example
Usage:
# Register server with all fields
uv run python cli/registry_mgmt.py register cli/examples/complete-server-example.json
# Register agent with all fields
uv run python cli/agent_mgmt.py register cli/examples/complete-agent-example.jsonCopy an example and modify the fields:
cp cli/examples/test_code_reviewer_agent.json cli/examples/my_custom_agent.jsonThen edit the JSON with your agent details:
{
"name": "My Custom Agent",
"path": "/my-agent",
"description": "What my agent does",
"url": "http://my-domain.com/agents/my-agent",
"version": "1.0.0",
"visibility": "public",
"trust_level": "community",
"tags": ["custom", "my-agent"],
"security_schemes": {
"bearer": {
"type": "bearer"
}
},
"protocol_version": "1.0"
}Register your agent:
export TOKEN="test-token"
uv run python cli/agent_mgmt.py register cli/examples/my_custom_agent.jsonAll agent JSON files must include:
name- Agent display name (string)path- Internal path identifier (string, must start with/)description- Brief description (string)url- Agent endpoint URL (string)version- Version number (string, e.g., "1.0.0")visibility- Public visibility (string: "public", "private", "community")trust_level- Trust classification (string)tags- Discovery tags (array of strings)security_schemes- Authentication config (object)protocol_version- A2A protocol version (string)
If you get: Error: Agent with path '/test-reviewer' already exists
Solution: Change the path in your JSON file or delete the existing agent.
If you get: Error: Validation failed - check agent JSON format
Solution: Verify all required fields are present and properly formatted. Validate with:
jq . cli/examples/test_code_reviewer_agent.jsonIf you get connection errors:
- Ensure the registry service is running
- Check it's on the correct port (default:
localhost:8000) - Verify with:
curl http://localhost:8000/api/health
After registration, agent files are stored in:
ls registry/agents/
cat registry/agents/test-reviewer.json
cat registry/agents/agent_state.json- Register a test agent
- View agents in the frontend dashboard
- Test agent accessibility
- Explore the admin panel for agent management
For complete documentation, see: .scratchpad/A2A_AGENT_CLI_REGISTRATION_GUIDE.md