| name | httpyac |
| description | Work with httpyac .http files for HTTP, gRPC, GraphQL, and WebSocket API testing and contract validation. Use when creating or executing API test requests. |
httpyac API Testing
Work with httpyac .http files to test and validate HTTP, gRPC, GraphQL, and WebSocket APIs following established patterns and best practices.
Quick Start
This Skill provides comprehensive rules for working with httpyac. Before any httpyac task:
- Read HTTPYAC-RULES.md for all protocol-specific rules
- STRICTLY follow these rules while creating or executing .http files
- RESPECT rules by severity: Critical [C] > High [H] > Medium [M] > Low [L]
- Understand proto file paths relative to .http file location for gRPC
When to Use This Skill
- Creating new .http files for API testing
- Writing HTTP REST requests with authentication
- Creating gRPC requests (unary or streaming)
- Crafting GraphQL queries and mutations
- Building WebSocket test scenarios
- Validating API contracts against proto definitions
- Debugging API integration issues
- Executing API tests via CLI
Rule Categories Overview
The HTTPYAC-RULES.md file contains detailed rules in these categories:
- [P] Protocol Selection: Choose appropriate protocol based on service definition
- [H] HTTP Requests: REST API patterns, headers, authentication, body formats
- [G] gRPC Requests: Proto imports, unary and streaming patterns, message formatting
- [Q] GraphQL Requests: Queries, mutations, fragments, variable passing
- [W] WebSocket Requests: Connections, streaming, bidirectional communication
- [M] Meta Data and Variables: Request naming, dependencies, variable scoping
- [S] Scripting and Testing: Pre/post-request scripts, assertions, async patterns
- [E] Environment and Configuration: CLI execution, proto path resolution, variables
Rule Severity Levels
- [C]ritical: Must never be violated - will cause execution failure
- [H]igh: Should almost never be violated - core patterns
- [M]edium: Follow unless good reason not to - best practices
- [L]ow: Guidelines and preferences - style choices
MCP Integration
This skill works best with:
serena MCP - for proto file discovery and navigation:
find_file: Locate proto files and existing .http examplesread_file: Read proto definitions to understand service contractssearch_for_pattern: Find existing patterns across .http filesget_symbols_overview: Understand proto service structurefind_symbol: Locate specific service methods
context7 MCP - for up-to-date httpyac documentation:
resolve-library-id: Get httpyac library IDget-library-docs: Fetch documentation for specific httpyac features
Troubleshooting
Proto file not found:
- Verify proto path is relative from .http file to proto file
- Count directories from .http file location to proto location
- Ensure
includeDirspoints to proto root directory for nested imports - Use serena MCP
find_fileto locate proto files
gRPC connection failure:
- Verify
{{HOST}}variable is defined - Check service and method names match proto exactly
- Ensure Authorization header if required
- Check gRPC status code in response (0 = success)
Variable not defined:
- Check if request has
@namemetadata for capture - Verify
@refor@forceReffor dependent requests - Check variable syntax:
{{variable}}not{variable} - Ensure referenced request executed before current request
CLI execution error:
- Use
-o=bodyfor output format and-ato execute all requests - Example:
httpyac -o=body -a ./path/to/file.http - Check if .http file path is correct relative to current directory
Example Workflow
When creating a new API test:
- Locate the proto file:
find_filewith pattern - Read proto to understand service contract:
read_file - Create .http file in desired location
- Calculate proto path relative to .http file location
- Add proto import with correct relative path and includeDirs
- Write request with proper protocol syntax
- Add variables and authentication
- Execute from CLI:
httpyac -o=body -a ./path/to/file.http - Add assertions in post-request script if needed